change from full depth clone to shallow clone

This commit is contained in:
2021-03-18 15:48:05 +01:00
parent 9e59a3ffc8
commit 5628d12579
3 changed files with 9 additions and 8 deletions

View File

@@ -20,9 +20,9 @@ a bunch of online resources.
Run one of the following install script commands (using curl, wget or fetch). Run one of the following install script commands (using curl, wget or fetch).
sh -c "$(curl -fsSL http://gogs.weseng.de/daniel/emacs/raw/master/scripts/install.sh)" sh -c "$(curl -fsSL http://gitea.weseng.de/daniel/emacs/raw/master/scripts/install.sh)"
sh -c "$(wget -O- http://gogs.weseng.de/daniel/emacs/raw/master/scripts/install.sh)" sh -c "$(wget -O- http://gitea.weseng.de/daniel/emacs/raw/master/scripts/install.sh)"
sh -c "$(fetch -o - http://gogs.weseng.de/daniel/emacs/raw/master/scripts/install.sh)" sh -c "$(fetch -o - http://gitea.weseng.de/daniel/emacs/raw/master/scripts/install.sh)"
Installation path is `~/.config/emacs`. See details and other Installation path is `~/.config/emacs`. See details and other
installed linux packages as requirements inside `sripts/install.sh`. installed linux packages as requirements inside `sripts/install.sh`.

View File

@@ -11,9 +11,9 @@ a bunch of online resources.
:END: :END:
Run one of the following install script commands (using curl, wget or fetch). Run one of the following install script commands (using curl, wget or fetch).
#+begin_src sh #+begin_src sh
sh -c "$(curl -fsSL http://gogs.weseng.de/daniel/emacs/raw/master/scripts/install.sh)" sh -c "$(curl -fsSL http://gitea.weseng.de/daniel/emacs/raw/master/scripts/install.sh)"
sh -c "$(wget -O- http://gogs.weseng.de/daniel/emacs/raw/master/scripts/install.sh)" sh -c "$(wget -O- http://gitea.weseng.de/daniel/emacs/raw/master/scripts/install.sh)"
sh -c "$(fetch -o - http://gogs.weseng.de/daniel/emacs/raw/master/scripts/install.sh)" sh -c "$(fetch -o - http://gitea.weseng.de/daniel/emacs/raw/master/scripts/install.sh)"
#+end_src #+end_src
Installation path is =~/.config/emacs=. See details and other Installation path is =~/.config/emacs=. See details and other

View File

@@ -106,7 +106,8 @@ case $distro in
folder="${HOME}/.config/emacs" folder="${HOME}/.config/emacs"
mkdir -p $folder mkdir -p $folder
echo "git clone" echo "git clone"
if ! git clone http://gogs.weseng.de/daniel/emacs.git "${folder}" 2>/dev/null && test -d "${folder}" ; then # shallow clone
if ! git clone --depth 1 http://gogs.weseng.de/daniel/emacs.git "${folder}" 2>/dev/null && test -d "${folder}" ; then
echo "clone failed because the folder ${folder} exists" echo "clone failed because the folder ${folder} exists"
fi fi