#!/bin/sh usage () { echo "usage:" $@ exit 127 } die () { echo $@ exit 128 } if test $# -lt 2 || test $# -gt 3 then usage "$0 []" fi orig_git=$1 new_workdir=$2 branch=$3 # want to make sure that what is pointed to has a .git directory ... git_dir=$(cd "$orig_git" 2>/dev/null && git rev-parse --git-dir 2>/dev/null) || die "Not a git repository: \"$orig_git\"" case "$git_dir" in .git) git_dir="$orig_git/.git" ;; .) git_dir=$orig_git ;; esac # don't link to a configured bare repository isbare=$(git --git-dir="$git_dir" config --bool --get core.bare) if test ztrue = z$isbare then die "\"$git_dir\" has core.bare set to true," \ " remove from \"$git_dir/config\" to use $0" fi # don't link to a workdir if test -L "$git_dir/config" then die "\"$orig_git\" is a working directory only, please specify" \ "a complete repository." fi # don't recreate a workdir over an existing repository if test -e "$new_workdir" then die "destination directory '$new_workdir' already exists." fi # make sure the links use full paths git_dir=$(cd "$git_dir"; pwd) # create the workdir mkdir -p "$new_workdir/.git" || die "unable to create \"$new_workdir\"!" # create the links to the original repo. explicitly exclude index, HEAD and # logs/HEAD from the list since they are purely related to the current working # directory, and should not be shared. for x in config refs logs/refs objects info hooks packed-refs remotes rr-cache svn do case $x in */*) mkdir -p "$(dirname "$new_workdir/.git/$x")" ;; esac ln -s "$git_dir/$x" "$new_workdir/.git/$x" done # now setup the workdir cd "$new_workdir" # copy the HEAD from the original repository as a default branch cp "$git_dir/HEAD" .git/HEAD # checkout the branch (either the same as HEAD from the original repository, or # the one that was asked for) git checkout -f $branch if test -n "$branch" then git merge --ff-only '@{upstream}' fi tion value='distro/collabora/cd-5.3-3.1'>distro/collabora/cd-5.3-3.1 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
ble class='list nowrap'>
AgeCommit message (Expand)Author
AgeCommit message (Expand)Author
2014-08-07Fix *_component_getFactory function typeStephan Bergmann
2014-08-01typo: more then -> more thanTakeshi Abe
2014-07-15fdo#80363 always use WIN32 long path prefix with Hunspell, MyThes, HyphenLászló Németh
2014-06-17conditionally revert 96840ff0ce697c5c05b59d53409b3cf27ac35e5fDouglas Mencken
2014-06-17improve the inlinesimplememberfunctions clang pluginNoel Grandin
2014-06-05various: remove SAL_THROW macroNoel Grandin
2014-06-04compareToAscii -> equalsAsciiNoel Grandin
2014-06-03WaE: 'guessesForWord:' is deprecated: first deprecated in OS X 10.6Tor Lillqvist
2014-05-23Try to fix Windows buildTor Lillqvist
2014-05-23Reintroduce Win_GetShortPathName()Tor Lillqvist
2014-05-23Fix typoTor Lillqvist
2014-05-23fdo#48017 WIN32 long path support in Hyphen and MyThesLászló Németh
2014-04-30Many spelling fixes: directories h* - p*.Pedro Giffuni
2014-04-28prefer makefile-gmake-modeTakeshi Abe
2014-04-25error C2059: syntax error : ´)´Caolán McNamara
2014-04-25fdo#48017 fix WIN32 long path name support of spelling dictionariesLászló Németh
2014-04-23lingucomponent: sal_Bool->boolNoel Grandin
2014-04-21Avoid possible memory leaks in case of exceptionsTakeshi Abe
2014-04-19fixincludeguards.sh: some smaller dirsThomas Arnhold
2014-04-14Clean up function declarationsStephan Bergmann
2014-04-14Clean up function declarationsStephan Bergmann
2014-03-30loplugin:saloverrideStephan Bergmann
2014-03-26First batch of adding SAL_OVERRRIDE to overriding function declarationsStephan Bergmann
2014-03-25WaE: unused variable 'catst2' [loplugin:unusedvariablecheck]Tor Lillqvist
2014-03-25coverity#735439 Logically dead codeCaolán McNamara
2014-02-26cppuhelper: retrofit std::exception into overriding exception specsStephan Bergmann
2014-02-26Remove visual noise from lingucomponentAlexander Wilms
2014-02-12normalize values of SYSTEM_ZLIB, SYSTEM_DICTS, SYSTEM_FONTCONFIGMichael Stahl
2014-02-11coverity#707953 Uninitialized scalar fieldCaolán McNamara
2014-02-04fdo#44314 Unicode hyphenation at soft hyphens with two extra char.László Németh
2014-01-30fdo#44314 non-standard hyphenation at soft hyphens + with pers. dic.László Németh
2014-01-30fdo#63154 Removed unused solar.h ref. in linguc., sfx2, starmath, svl and svxAlexandre Vicenzi
2014-01-01Drop the unnecessary extra directory levelKhaled Hosny
2013-12-26WaE: unused variable 'aPathOpt'Tor Lillqvist
2013-12-20typo fixesAndras Timar
2013-12-17Adapt all (non-extension, SharedLibrary) .components to environment="..."Stephan Bergmann
2013-12-16Clean-up uno/lbnames.hStephan Bergmann
2013-12-09Revert "fdo#56443 allow different name for .dic and .aff files"Andras Timar
2013-12-09fdo#56443 allow different name for .dic and .aff filesAndras Timar
2013-11-14remove unnecessary sal_Unicode casts in various placesNoel Grandin
2013-11-11convert OUString !compareToAscii to equalsAsciiNoel Grandin
2013-10-31Convert indexOf->startsWith and lastIndexOf->endsWithNoel Grandin