Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
exam-print-script
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
A-SAM
exam-print-script
Commits
cc4c8e19
Commit
cc4c8e19
authored
Aug 28, 2017
by
Filippo Leonardi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add support for cpp files and 'C Source files'
parent
b082dcee
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
latex_creator.py
latex_creator.py
+7
-1
latex_creator_main.py
latex_creator_main.py
+1
-1
No files found.
latex_creator.py
View file @
cc4c8e19
...
...
@@ -18,7 +18,7 @@ symlink_prefix = '_____'
# used to grep with command `file`
image_formats
=
[
'PNG image data'
,
'JPEG image data'
,
'PDF document'
]
code_formats
=
[
'Python script'
,
'C source'
,
'C header'
,
'C++ source'
,
'C++ header'
,
'MATLAB'
]
'C++ header'
,
'MATLAB'
,
'C++ source file'
,
'C source file'
]
text_formats
=
[
'ASCII text'
,
'UTF-8 Unicode text'
]
# Sometimes "file" fails and recognises a ".cpp" file as "C source",
...
...
@@ -34,6 +34,8 @@ short_names = {'PNG image data': 'PNG',
'C header'
:
'HPP'
,
'C++ source'
:
'CPP'
,
'C++ header'
:
'HPP'
,
'C++ source file'
:
'CPP'
,
'C source file'
:
'CPP'
,
None
:
'None'
}
# Set listing language to the one on the right
...
...
@@ -42,6 +44,8 @@ listing_names = {'Python script': 'python',
'C header'
:
'C++'
,
'C++ source'
:
'C++'
,
'C++ header'
:
'C++'
,
'C++ source file'
:
'C++'
,
'C source file'
:
'C++'
,
'ASCII text'
:
''
,
'UTF-8 Unicode text'
:
''
,
'MATLAB'
:
'Matlab'
,
...
...
@@ -52,6 +56,8 @@ style_names = {'Python script': 'PY',
'MATLAB'
:
'MATLAB'
,
'C source'
:
'CPP'
,
'C header'
:
'CPP'
,
'C++ source file'
:
'CPP'
,
'C source file'
:
'CPP'
,
'C++ source'
:
'CPP'
,
'C++ header'
:
'CPP'
,
'ASCII text'
:
''
,
...
...
latex_creator_main.py
View file @
cc4c8e19
#!/usr/bin/env python
#!/usr/bin/env python
2
import
argparse
import
os
,
re
import
subprocess
...
...
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