Skip to content

Commit

Permalink
Merge pull request #6 from hebrewsnabla/v1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanwsr authored Oct 31, 2022
2 parents f9ae032 + 837a795 commit 581d508
Show file tree
Hide file tree
Showing 16 changed files with 132 additions and 7 deletions.
46 changes: 46 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Build

on:
push:
branches:
- master

pull_request:
branches:
- master

env:
CTAN_URL: https://mirrors.rit.edu/CTAN
TL_PACKAGES: abstract amscls amsmath amsfonts anyfontsize blkarray booktabs braket caption endnotes extarrows fancyhdr fandol float fontspec graphics hyperref jknapltx latexmk libertinus-fonts luatex85 l3packages mathalpha mathtools metafont mhchem multirow needspace newfloat paralist pgfplots psnfss physics scalerel sectsty siunitx subfig threeparttable tikz-feynman times tocbibind tocloft tools ulem xcolor xecjk collection-fontsrecommended collection-fontsextra

jobs:
build-on-ubuntu:
runs-on: ubuntu-latest
if: "!startsWith(github.ref, 'refs/tags/v')"
env:
SET_PATH: |
export PATH=/tmp/texlive/bin/x86_64-linux:$PATH
steps:
- name: Set up Git repository
uses: actions/checkout@v3

- name: Install TeX Live
run: |
${{ env.SET_PATH }}
wget ${{ env.CTAN_URL }}/systems/texlive/tlnet/install-tl-unx.tar.gz
tar -xzf install-tl-unx.tar.gz
cd install-tl-20* && ./install-tl --profile ../.github/workflows/texlive.profile
tlmgr install ${{ env.TL_PACKAGES }}
tlmgr update --self --all --no-auto-install --repository=${{ env.CTAN_URL }}/systems/texlive/tlnet/
- name: Compile test file
run: |
${{ env.SET_PATH }}
bash release.sh latest
#cd test
#latexmk -xelatex -halt-on-error -shell-escape main
- name: Upload PDF
uses: actions/upload-artifact@v3
with:
name: SzaboSolutions-latest
path:
./release/SzaboSolutions-latest/
50 changes: 50 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Release

on:
push:
branches:
- master

tags:
- v*

env:
CTAN_URL: https://mirrors.rit.edu/CTAN
TL_PACKAGES: abstract amscls amsfonts amsmath anyfontsize blkarray booktabs braket caption endnotes extarrows fancyhdr fandol float fontspec graphics hyperref jknapltx latexmk libertinus-fonts luatex85 l3packages mathalpha mathtools metafont mhchem multirow needspace newfloat paralist pgfplots psnfss physics scalerel sectsty siunitx subfig threeparttable tikz-feynman times tocbibind tocloft tools ulem xcolor xecjk collection-fontsrecommended collection-fontsextra

jobs:
release:
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/v')
env:
SET_PATH: |
export PATH=/tmp/texlive/bin/x86_64-linux:$PATH
steps:
- name: Set up Git repository
uses: actions/checkout@v3

- name: Set Version
run: echo "VERSION=${GITHUB_REF##*/}" >> $GITHUB_ENV

- name: Install TeX Live
run: |
${{ env.SET_PATH }}
wget ${{ env.CTAN_URL }}/systems/texlive/tlnet/install-tl-unx.tar.gz
tar -xzf install-tl-unx.tar.gz
cd install-tl-20* && ./install-tl --profile ../.github/workflows/texlive.profile
tlmgr install ${{ env.TL_PACKAGES }}
tlmgr update --self --all --no-auto-install --repository=${{ env.CTAN_URL }}/systems/texlive/tlnet/
- name: Compile test file
run: |
${{ env.SET_PATH }}
bash release.sh $VERSION
#cd test
#latexmk -xelatex -halt-on-error -shell-escape main
- name: Create release
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: true
files: |
./release/SzaboSolutions-$VERSION/
15 changes: 15 additions & 0 deletions .github/workflows/texlive.profile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# From latex3
# https://github.com/latex3/latex3/blob/main/support/texlive.profile

selected_scheme scheme-infraonly
TEXDIR /tmp/texlive
TEXMFSYSCONFIG /tmp/texlive/texmf-config
TEXMFSYSVAR /tmp/texlive/texmf-var
TEXMFLOCAL /tmp/texlive/texmf-local
TEXMFHOME ~/texmf
TEXMFCONFIG ~/.texlive/texmf-config
TEXMFVAR ~/.texlive/texmf-var
option_doc 0
option_src 0
tlpdbopt_autobackup 0

5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@
*.gz
*.toc
*.out
*.fdb*
*.fls
*.xdv
sol/*
*.djvu
notes/*xlsx
release/*
chap*/chap*.pdf
appendix/appendix.pdf
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Solutions for Modern Quantum Chemistry, Szabo & Ostlund

Compiled with XeLaTeX. TeXLive 2020 or 2021 is recommended.
Compiled with XeLaTeX. TeXLive 2020-latest is recommended.

References
## Note
Since v1.2, we move the pdf to releases to reduce the size of the repo, which is auto-compiled by GitHub Actions. But the compilation may still have problems. If you find the released pdf is wrong, plase check the old v1.1 branch, which still keep pdf files, to confirm and report the bug.

## References
* [gensoukyo.me/Modern-Quantum-Chemistry-习题解答](https://gensoukyo.me/Modern-Quantum-Chemistry-%E4%B9%A0%E9%A2%98%E8%A7%A3%E7%AD%94/)
* [www.claudiug.com/9780486691862/](https://www.claudiug.com/9780486691862/)
Binary file removed appendix/appendix.pdf
Binary file not shown.
Binary file removed chap1/chap1.pdf
Binary file not shown.
2 changes: 1 addition & 1 deletion chap1/chap1.tex
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ \subsubsection{Matrices}
\subex{c.}
\begin{equation}\label{key}
\vb{B} = \vb{U}^\dagger \vb{A} \vb{U}
\end{equation}huhhj
\end{equation}
\begin{equation}\label{key}
\vb{U} \vb{B} \vb{U}^\dagger = \vb{U} \vb{U}^\dagger \vb{A} \vb{U} \vb{U}^\dagger = \iden \vb{A} \iden = \vb{A}
\end{equation}
Expand Down
Binary file removed chap2/chap2.pdf
Binary file not shown.
Binary file removed chap3/chap3.pdf
Binary file not shown.
Binary file removed chap4/chap4.pdf
Binary file not shown.
Binary file removed chap5/chap5.pdf
Binary file not shown.
Binary file removed chap6/chap6.pdf
Binary file not shown.
Binary file removed chap7/chap7.pdf
Binary file not shown.
2 changes: 1 addition & 1 deletion mqc.sty
Original file line number Diff line number Diff line change
Expand Up @@ -169,5 +169,5 @@

\usepackage{xcolor}
\definecolor{codegray}{gray}{0.9}
\newfontfamily\Consolas{Consolas}
\newfontfamily\Consolas{inconsolata}
\newcommand{\code}[1]{\colorbox{codegray}{{\Consolas#1}}}
12 changes: 9 additions & 3 deletions release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,22 @@ mkdir -p release
mkdir -p $targ
for i in {1..7}
do
cp chap$i/chap$i.pdf $targ
cd chap$i
latexmk -xelatex -halt-on-error -shell-escape chap$i
cp chap$i.pdf ../$targ
cd ..
done
cp appendix/appendix.pdf $targ
cd appendix
latexmk -xelatex -halt-on-error -shell-escape appendix
cp appendix.pdf ../$targ
cd ..

mkdir -p $targ/codes
for j in chap1/1-1.nb chap1/1-3.nb "chap4/4-11,12.nb" "chap4/4-14,15.nb" chap5/5-7.nb chap5/5-9+.nb chap5/5-12.nb chap5/5-16+.nb chap6/6-6.nb appendix/C-3.py appendix/C-4.py
do
cp $j $targ/codes
done

tar czvf $targ.tar.gz $targ
#tar czvf $targ.tar.gz $targ


0 comments on commit 581d508

Please sign in to comment.