Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
astron-texmf
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ASTRON SDC
Documents
astron-texmf
Commits
cfebf9f2
Commit
cfebf9f2
authored
4 years ago
by
John Swinbank
Browse files
Options
Downloads
Patches
Plain Diff
Provide template Makefile
parent
27d17c22
No related branches found
Branches containing commit
No related tags found
1 merge request
!15
Provide template Makefile
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
example/Makefile
+1
-15
1 addition, 15 deletions
example/Makefile
vcs-meta.make
+14
-0
14 additions, 0 deletions
vcs-meta.make
with
15 additions
and
15 deletions
example/Makefile
+
1
−
15
View file @
cfebf9f2
DOCNAME
=
example
export
TEXMFHOME
?=
../texmf
GITVERSION
:=
$(
shell git describe
--always
--dirty
)
GITDATE
:=
$(
shell git log
-1
--date
=
short
--pretty
=
%ad
)
GITFIRSTYEAR
:=
$(
shell git log
--reverse
--date
=
short
--format
=
"format:%ad"
|
head
-1
|
cut
-d-
-f1
)
GITLASTYEAR
:=
$(
shell git log
-1
--date
=
short
--pretty
=
%ad |
cut
-d-
-f1
)
$(DOCNAME).pdf
:
$(DOCNAME).tex meta.tex
xelatex
$(
DOCNAME
)
makeglossaries
$(
DOCNAME
)
...
...
@@ -14,12 +8,4 @@ $(DOCNAME).pdf: $(DOCNAME).tex meta.tex
xelatex
$(
DOCNAME
)
xelatex
$(
DOCNAME
)
.FORCE
:
meta.tex
:
Makefile .FORCE
rm
-f
$@
printf
"%s
\n
"
"% GENERATED FILE -- edit this in the Makefile"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csRevision}{
$(
GITVERSION
)$(
GITDIRTY
)
}"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csDate}{
$(
GITDATE
)
}"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csFirstYear}{
$(
GITFIRSTYEAR
)
}"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csLastYear}{
$(
GITLASTYEAR
)
}"
>>
$@
include
../vcs-meta.make
This diff is collapsed.
Click to expand it.
vcs-meta.make
0 → 100644
+
14
−
0
View file @
cfebf9f2
GITVERSION
:=
$(
shell git describe
--always
--dirty
)
GITDATE
:=
$(
shell git log
-1
--date
=
short
--pretty
=
%ad
)
GITFIRSTYEAR
:=
$(
shell git log
--reverse
--date
=
short
--pretty
=
%ad |
head
-1
|
cut
-d-
-f1
)
GITLASTYEAR
:=
$(
shell git log
-1
--date
=
short
--pretty
=
%ad |
cut
-d-
-f1
)
.FORCE
:
meta.tex
:
Makefile .FORCE
rm
-f
$@
printf
"%s
\n
"
"% GENERATED FILE -- edit this in the Makefile"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csRevision}{
$(
GITVERSION
)
}"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csDate}{
$(
GITDATE
)
}"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csFirstYear}{
$(
GITFIRSTYEAR
)
}"
>>
$@
printf
"%s
\n
"
"
\n
ewcommand{
\v
csLastYear}{
$(
GITLASTYEAR
)
}"
>>
$@
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment