New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Install reqired tlmgr
in install script if necessary
#215
Merged
Merged
Changes from 3 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
4d1194d
Revert "Revert "install tlmgr util if necessary""
howcanunot 37f04db
Revert "Revert "Revert "install tlmgr util if necessary"""
howcanunot 3f45901
fix commits
howcanunot 892991b
make install working for every platform
howcanunot 74dc764
fix if statement
howcanunot e4cbb5e
fix if statement
howcanunot 9bf57ac
export PATH
howcanunot de10cb9
change inside if
howcanunot 1f0fb89
Merge branch 'yegor256:master' into fix-install-script
howcanunot b4f0b8b
Merge branch 'master' of github.com:howcanunot/cam into fix-install-s…
howcanunot 6027ad9
pulled from upstream
howcanunot 7bf7876
some fixes
howcanunot File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,77 +47,40 @@ if [ -n "${linux}" ]; then | |
apt-get install -y coreutils | ||
fi | ||
|
||
if ! parallel --version >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get -y install parallel | ||
else | ||
echo "Install 'parallel' somehow" | ||
exit 1 | ||
install_or_quit() { | ||
if ! dpkg -s "$1" >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get -y install "$1" | ||
else | ||
echo "Install '$1' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
fi | ||
|
||
if ! bc -v >/dev/null 2>&1; then | ||
} | ||
|
||
install_or_quit 'parallel' | ||
install_or_quit 'bc' | ||
install_or_quit 'cloc' | ||
install_or_quit 'jq' | ||
install_or_quit 'xpdf' | ||
install_or_quit 'shellcheck' | ||
install_or_quit 'aspell' | ||
install_or_quit 'xmlstarlet' | ||
|
||
if [ ! -f "/usr/local/texlive/$(date +%Y)/bin/x86_64-linux/tlmgr" ]; then | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @howcanunot how about MacOS? |
||
if [ -n "${linux}" ]; then | ||
apt-get install -y bc | ||
wget https://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz && \ | ||
zcat < install-tl-unx.tar.gz | tar xf - && \ | ||
rm install-tl-unx.tar.gz && \ | ||
cd install-tl-$(date +%Y)* && \ | ||
perl ./install-tl --scheme=e --no-interaction | ||
else | ||
echo "Install 'GNU bc' somehow" | ||
echo "Install 'texlive-base' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
|
||
if ! cloc --version >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y cloc | ||
else | ||
echo "Install 'cloc' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
|
||
if ! jq --version >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y jq | ||
else | ||
echo "Install 'jq' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
|
||
if ! pdftotext -v >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y xpdf | ||
else | ||
echo "Install 'poppler' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
|
||
if ! shellcheck --version >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y shellcheck | ||
else | ||
echo "Install 'shellcheck' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
|
||
if ! aspell --version >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y aspell | ||
else | ||
echo "Install 'GNU aspell' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
|
||
if ! xmlstarlet --version >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y xmlstarlet | ||
else | ||
echo "Install 'xmlstarlet' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
export PATH=/usr/local/texlive/$(date +%Y)/bin/x86_64-linux:$PATH | ||
|
||
if [ ! -e "${HOME}/texmf" ]; then | ||
$SUDO tlmgr init-usertree | ||
|
@@ -132,14 +95,7 @@ done < <( cut -d' ' -f2 "${root}/../DEPENDS.txt" | uniq ) | |
$SUDO tlmgr --verify-repo=none install "${packages[@]}" | ||
$SUDO tlmgr --verify-repo=none update --no-auto-remove "${packages[@]}" || echo 'Failed to update' | ||
|
||
if ! pygmentize -V >/dev/null 2>&1; then | ||
if [ -n "${linux}" ]; then | ||
apt-get install -y python3-pygments | ||
else | ||
echo "Install 'python3-pygments' somehow" | ||
exit 1 | ||
fi | ||
fi | ||
install_or_quit 'python3-pygments' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @howcanunot there is no |
||
|
||
$SUDO python3 -m pip install --upgrade pip | ||
$SUDO python3 -m pip install -r "${LOCAL}/requirements.txt" | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@howcanunot there is no
dpkg
in MacOS :)