add notes about auto zim git push
This commit is contained in:
parent
29077b6cfc
commit
1352be08c8
29
Home/AutoZimGitPush.txt
Normal file
29
Home/AutoZimGitPush.txt
Normal file
@ -0,0 +1,29 @@
|
||||
Content-Type: text/x-zim-wiki
|
||||
Wiki-Format: zim 0.6
|
||||
Creation-Date: 2023-10-26T14:44:31+03:00
|
||||
|
||||
====== AutoZimGitPush ======
|
||||
Created neljapäev 26 oktoober 2023
|
||||
|
||||
===== First Time config =====
|
||||
|
||||
''cd ~/Notebooks/Notes''
|
||||
''git remote add origin'' [[gitea@git.wut.ee|''gitea@git.wut.ee'']]'':arti/zim.git''
|
||||
''git push -u origin main''
|
||||
|
||||
===== Auto push =====
|
||||
You have to create git hook that runs after each git commit
|
||||
|
||||
''cd ~/Notebooks/Notes''
|
||||
''nano .git/hooks/post-commit''
|
||||
|
||||
with contents
|
||||
{{{code: lang="sh" linenumbers="True"
|
||||
#!/bin/bash
|
||||
git push
|
||||
|
||||
}}}
|
||||
and make it executable
|
||||
|
||||
''chmod +x .git/hooks/post-commit''
|
||||
|
Loading…
Reference in New Issue
Block a user