Skip to content

Instantly share code, notes, and snippets.

@lingtalfi
Created January 17, 2016 06:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lingtalfi/40729e4f6e4bf172a130 to your computer and use it in GitHub Desktop.
Save lingtalfi/40729e4f6e4bf172a130 to your computer and use it in GitHub Desktop.
export local app using git command (personal memo)
### Gitization du project local
cd "/path/to/myapp"
git init
git snap initial commit
copen .gitignore
<<<
.idea/
conception/
design/
private/
todo/
videos/
.gitignore
uploaded/
>>>
git snap initial commit
### Export du site sur la machine distante
komin
(distant)
cd "/home/ling/websites"
mkdir myapp
cd myapp
(local)
_scp .git /home/ling/websites/myapp/.git
git remote add origin komin:websites/myapp
(distant)
git config receive.denyCurrentBranch ignore
git config core.worktree ../
cp .git/hooks/post-update.sample .git/hooks/post-update
pico .git/hooks/post-update
<<<
#!/bin/sh
exec git reset --hard
>>>
(local)
(make some changes)
git snap first export commit
git pp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment