Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
J
jekyll-scholar-extras
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
caesr-pub
jekyll-scholar-extras
Commits
5c88e691
Commit
5c88e691
authored
Mar 01, 2017
by
rmrf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix: CI error
Add .to_i is there for positional insertions
parent
1d7fea3b
Pipeline
#31433
passed with stages
in 42 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
5 deletions
+4
-5
lib/jekyll/scholar/extras/bibliography_bytype.rb
lib/jekyll/scholar/extras/bibliography_bytype.rb
+2
-2
lib/jekyll/scholar/extras/bibliography_year.rb
lib/jekyll/scholar/extras/bibliography_year.rb
+2
-3
No files found.
lib/jekyll/scholar/extras/bibliography_bytype.rb
View file @
5c88e691
...
...
@@ -111,12 +111,12 @@ module Jekyll
# Is there a link for code
if
entry
.
field?
(
:code
)
code_url
=
"<div class=
\"
pure-button csl-code
\"
><a href=
\"
"
+
entry
.
code
.
to_s
+
"
\"
>CODE</a></div>"
reference
.
insert
(
reference
.
rindex
(
'</div>'
),
code_url
.
to_s
)
reference
.
insert
(
reference
.
rindex
(
'</div>'
)
.
to_i
,
code_url
.
to_s
)
end
# Generate the bibtex button
tex_bib
=
"<div class=
\"
pure-button csl-bibtex
\"
><a href=
\"
"
+
bibtex_link_for
(
entry
).
to_s
+
"
\"
>BIBTEX</a></div>"
reference
.
insert
(
reference
.
rindex
(
'</div>'
),
tex_bib
.
to_s
)
reference
.
insert
(
reference
.
rindex
(
'</div>'
)
.
to_i
,
tex_bib
.
to_s
)
content_tag
config
[
'bibliography_item_tag'
],
reference
content_tag
"li class=
\"
"
+
render_ref_img
(
entry
)
+
"
\"
"
,
reference
...
...
lib/jekyll/scholar/extras/bibliography_year.rb
View file @
5c88e691
...
...
@@ -134,7 +134,7 @@ module Jekyll
# Is there a link for code
if
entry
.
field?
(
:code
)
code_url
=
"<div class=
\"
pure-button csl-code
\"
><a href=
\"
"
+
entry
.
code
.
to_s
+
"
\"
>CODE</a></div>"
reference
.
insert
(
reference
.
rindex
(
'</div>'
),
code_url
.
to_s
)
reference
.
insert
(
reference
.
rindex
(
'</div>'
)
.
to_i
,
code_url
.
to_s
)
end
...
...
@@ -142,8 +142,7 @@ module Jekyll
# Generate the bibtex button for all pubs
tex_bib
=
"<div class=
\"
pure-button csl-bibtex
\"
><a href=
\"
"
+
bibtex_link_for
(
entry
).
to_s
+
"
\"
>BIBTEX</a></div>"
puts
reference
.
rindex
(
'</div>'
)
reference
.
insert
(
reference
.
rindex
(
'</div>'
),
tex_bib
.
to_s
)
reference
.
insert
(
reference
.
rindex
(
'</div>'
).
to_i
,
tex_bib
.
to_s
)
# Content tag is dependent on type of article.
content_tag
"li class=
\"
"
+
render_ref_img
(
entry
)
+
"
\"
"
,
reference
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment