gistfile1.txt
· 444 B · Text
Raw
#! /bin/sh
# create an opengist file and push it to the server
#
# alexlehm/at/gmail.com
TMP=git.gist.$$
mkdir $TMP
cp $1 $TMP/
cd $TMP
git init
git config credential.helper store
git add .
git commit -m "automatic upload"
# if default branch is main, change to master, otherwise we confuse opengist
git branch master
git checkout master
git remote add origin http://wormhole.axs.de:6157/init
git push -u origin master
cd ..
rm -rf $TMP
1 | #! /bin/sh |
2 | |
3 | # create an opengist file and push it to the server |
4 | # |
5 | # alexlehm/at/gmail.com |
6 | |
7 | TMP=git.gist.$$ |
8 | |
9 | mkdir $TMP |
10 | |
11 | cp $1 $TMP/ |
12 | |
13 | cd $TMP |
14 | git init |
15 | git config credential.helper store |
16 | git add . |
17 | git commit -m "automatic upload" |
18 | # if default branch is main, change to master, otherwise we confuse opengist |
19 | git branch master |
20 | git checkout master |
21 | git remote add origin http://wormhole.axs.de:6157/init |
22 | git push -u origin master |
23 | |
24 | cd .. |
25 | rm -rf $TMP |
26 | |
27 |