Roland's homepage

My random knot in the Web

Moving scripts to a private repo

date: 2015-05-14
reading time: 2 min.
category: problems
tags: git

Some of the scripts in my scripts directory are private because they contain personally identifying or security relevant information, or are just not useful for others without modifications. So I decided not to publish it on github as-is, but to make a private repo for scripts that are not for general use.

What I did was create a fast-export stream for the files that are suitable for publication.

cd ~/src/scripts
git fast-export HEAD -- backup-local.sh checkfor.py clean-keyring.sh \
clean.sh  clock.sh csv2tbl.py dicom2png.py ffmutt.sh find-modified.sh \
fixbb.sh genbackup.sh genotp.py genpw.py git-check-all.py \
git-origdate.py gitdates.py histdata.py img4latex.py ips.sh jpeg2pdf.sh \
make-flac.py make-mp3.py mkdistinfo.sh mkindexpic.sh mkpdf.sh \
mkphotopage.py nospaces.py old.py open.py pdfselect.sh pdftopdf.sh \
povmake.sh py-ver.py raw2pgm.sh serve-git.sh set-title.sh setres.sh \
sha256.py tifftopdf.py tolower.sh vid2mkv.py vid2mp4.py >../pub.fi

This was then imported into a fresh directory.

cd ~/src
mkdir public-scripts
cd public-scripts
git init .
git fast-import <../pub.fi

In the original (now private) repo, I used git rm to remove the files that are now in the public repo. I did not bother trying to expunge the complete history of those files.


For comments, please send me an e-mail.


Related articles


←  Making my first e-book Converting RCS history to git  →