]> git.phdru.name Git - git-scripts.git/log
git-scripts.git
4 years agoFeat(hooks/post-update): Push back to `origin`
Oleg Broytman [Fri, 14 Aug 2020 15:15:09 +0000 (18:15 +0300)]
Feat(hooks/post-update): Push back to `origin`

4 years agoFeat(hooks/post-update): Add remote `origin` if not exists
Oleg Broytman [Fri, 14 Aug 2020 15:13:11 +0000 (18:13 +0300)]
Feat(hooks/post-update): Add remote `origin` if not exists

4 years agoFeat(fix-detached-head): Replace `branch -r` by `for-each-ref`
Oleg Broytman [Tue, 4 Aug 2020 15:22:40 +0000 (18:22 +0300)]
Feat(fix-detached-head): Replace `branch -r` by `for-each-ref`

Use `git for-each-ref` instead of `git branch -r | sed`.

4 years agoFeat(fix-detached-head): Get branch from superproject
Oleg Broytman [Tue, 4 Aug 2020 15:20:27 +0000 (18:20 +0300)]
Feat(fix-detached-head): Get branch from superproject

Get the branch from the superproject's `.gitmodules`.

4 years agoFeat: Fix detached `HEAD`
Oleg Broytman [Mon, 3 Aug 2020 15:04:52 +0000 (18:04 +0300)]
Feat: Fix detached `HEAD`

Fix detached `HEAD` by checking out the branch
(local or remote, if one exists) that points to the same commit.

4 years agoFeat: Check recursively for detached `HEAD`
Oleg Broytman [Sun, 2 Aug 2020 22:52:02 +0000 (01:52 +0300)]
Feat: Check recursively for detached `HEAD`

4 years agoFeat(sparse-clone): Add options parser
Oleg Broytman [Tue, 12 May 2020 12:07:01 +0000 (15:07 +0300)]
Feat(sparse-clone): Add options parser

Parametrize branch (default is master)
and local directory (default is the name of the remote repo).

4 years agoFeat(sparse-clone): Validate parameters
Oleg Broytman [Tue, 12 May 2020 10:52:27 +0000 (13:52 +0300)]
Feat(sparse-clone): Validate parameters

4 years agoGet local directory name from origin
Oleg Broytman [Tue, 12 May 2020 10:49:31 +0000 (13:49 +0300)]
Get local directory name from origin

4 years agoAdd `run-bare-repos`: run a command over all bare repositories
Oleg Broytman [Fri, 17 Apr 2020 15:41:21 +0000 (18:41 +0300)]
Add `run-bare-repos`: run a command over all bare repositories

4 years agoFeat(reinit): Split `reinit-all`
Oleg Broytman [Fri, 17 Apr 2020 11:32:15 +0000 (14:32 +0300)]
Feat(reinit): Split `reinit-all`

4 years agoAdd `sparse-clone`
Oleg Broytman [Fri, 17 Apr 2020 11:19:19 +0000 (14:19 +0300)]
Add `sparse-clone`

4 years agoFix(set-commit-date.py): Skip symlinks
Oleg Broytman [Sun, 2 Feb 2020 15:43:33 +0000 (18:43 +0300)]
Fix(set-commit-date.py): Skip symlinks

An earlier symlink to a file should not override the later file.

4 years agoFeat(svn): Add script `rdump-load`
Oleg Broytman [Sat, 1 Feb 2020 09:26:38 +0000 (12:26 +0300)]
Feat(svn): Add script `rdump-load`

Dump remote Subversion repository and load it into a local one
to speed up following `git-svn` operations.

4 years agoFix(svn/get-authors): Append to existing `authors.txt`
Oleg Broytman [Sat, 1 Feb 2020 07:31:45 +0000 (10:31 +0300)]
Fix(svn/get-authors): Append to existing `authors.txt`

4 years agoFeat(svn/get-authors): Add perl-based parser
Oleg Broytman [Sat, 1 Feb 2020 07:31:45 +0000 (10:31 +0300)]
Feat(svn/get-authors): Add perl-based parser

4 years agoFix(svn/get-authors): Pass URL
Oleg Broytman [Sat, 1 Feb 2020 07:31:45 +0000 (10:31 +0300)]
Fix(svn/get-authors): Pass URL

4 years agoFeat(locate-all): Use `sort -u` instead of `sort | uniq`
Oleg Broytman [Mon, 23 Dec 2019 02:31:26 +0000 (05:31 +0300)]
Feat(locate-all): Use `sort -u` instead of `sort | uniq`

4 years agoDoc(locate-all): Add comments
Oleg Broytman [Mon, 23 Dec 2019 02:30:31 +0000 (05:30 +0300)]
Doc(locate-all): Add comments

4 years agoRefactor(locate-all): Reorder excluded directories
Oleg Broytman [Mon, 23 Dec 2019 02:28:00 +0000 (05:28 +0300)]
Refactor(locate-all): Reorder excluded directories

4 years agoFeat(set-commit-date): Allow to choose between author and committer date
Oleg Broytman [Fri, 20 Dec 2019 18:19:51 +0000 (21:19 +0300)]
Feat(set-commit-date): Allow to choose between author and committer date

Default is committer date.

4 years agoFeat(locate-all): Exclude submodules
Oleg Broytman [Wed, 18 Dec 2019 01:53:31 +0000 (04:53 +0300)]
Feat(locate-all): Exclude submodules

Check submodules by files `.git`.

5 years agoRefactor: Use `$#` to check parameters
Oleg Broytman [Thu, 15 Aug 2019 18:57:11 +0000 (21:57 +0300)]
Refactor: Use `$#` to check parameters

5 years agoRefactor(set-commit-date.py): Combine 2 conditions
Oleg Broytman [Sat, 3 Aug 2019 11:22:42 +0000 (14:22 +0300)]
Refactor(set-commit-date.py): Combine 2 conditions

5 years agoFix(set-commit-date.py): Consider deleted files
Oleg Broytman [Fri, 2 Aug 2019 18:10:42 +0000 (21:10 +0300)]
Fix(set-commit-date.py): Consider deleted files

If the file was deleted and later readded - ignore deletion.
Otherwise ignore deleted files.

5 years agoAdd git-submodules-add
Oleg Broytman [Fri, 7 Jun 2019 09:49:46 +0000 (12:49 +0300)]
Add git-submodules-add

Run `git submodule add` on submodules in `.gitmodules`
if said `.gitmodules` has been simply copied into the project.

5 years agoFix(set-commit-date-repos): Remove excessive apostrophe
Oleg Broytman [Fri, 31 May 2019 15:57:50 +0000 (18:57 +0300)]
Fix(set-commit-date-repos): Remove excessive apostrophe

5 years agoFeat(git-open): Replace scp URLs with https
Oleg Broytman [Thu, 14 Mar 2019 15:08:44 +0000 (18:08 +0300)]
Feat(git-open): Replace scp URLs with https

5 years agoFeat(get-authors): Add an alternative implementation
Oleg Broytman [Tue, 12 Mar 2019 15:46:32 +0000 (18:46 +0300)]
Feat(get-authors): Add an alternative implementation

5 years agoFix: Remove excessive redirection and exit code check
Oleg Broytman [Fri, 1 Mar 2019 22:50:34 +0000 (01:50 +0300)]
Fix: Remove excessive redirection and exit code check

5 years agoFix(ls-no-description): Print cwd (`$g` can be just '.')
Oleg Broytman [Thu, 28 Feb 2019 16:34:47 +0000 (19:34 +0300)]
Fix(ls-no-description): Print cwd (`$g` can be just '.')

5 years agoRefactoring: Factor out run-repos and run-workdirs
Oleg Broytman [Thu, 28 Feb 2019 12:56:47 +0000 (15:56 +0300)]
Refactoring: Factor out run-repos and run-workdirs

5 years agoRemove excessive `echo`; simplify long commands
Oleg Broytman [Thu, 28 Feb 2019 12:27:57 +0000 (15:27 +0300)]
Remove excessive `echo`; simplify long commands

5 years agoFeat: Split scripts into 3: run in one repo, recursive, in all
Oleg Broytman [Thu, 28 Feb 2019 00:53:03 +0000 (03:53 +0300)]
Feat: Split scripts into 3: run in one repo, recursive, in all

5 years agoRefactor: Factor out run-recursive
Oleg Broytman [Wed, 27 Feb 2019 23:24:11 +0000 (02:24 +0300)]
Refactor: Factor out run-recursive

5 years agoAdd scripts to run fsck of all repositories
Oleg Broytman [Fri, 18 Jan 2019 03:12:29 +0000 (06:12 +0300)]
Add scripts to run fsck of all repositories

5 years agoRename all-status -> status-all
Oleg Broytman [Fri, 18 Jan 2019 03:12:06 +0000 (06:12 +0300)]
Rename all-status -> status-all

5 years agoFeat(set-commit-date.py): chdir to git root
Oleg Broytman [Tue, 27 Nov 2018 19:27:09 +0000 (22:27 +0300)]
Feat(set-commit-date.py): chdir to git root

Necessary because `git --log --name-only` produces paths relative to
the root.

6 years agoAdd post-update to update git-scripts after pushing to git-scripts.git
Oleg Broytman [Fri, 28 Sep 2018 15:05:54 +0000 (18:05 +0300)]
Add post-update to update git-scripts after pushing to git-scripts.git

6 years agoI stopped using `git-remote-hg`
Oleg Broytman [Tue, 21 Aug 2018 06:24:05 +0000 (09:24 +0300)]
I stopped using `git-remote-hg`

All repositories migrated long ago.

6 years agoRefactor(set-commit-date.py): Use git_log.stdout as an iterator
Oleg Broytman [Fri, 27 Apr 2018 21:41:01 +0000 (00:41 +0300)]
Refactor(set-commit-date.py): Use git_log.stdout as an iterator

6 years agoFeat: Run set-commit-date-recursive on clone/fork
Oleg Broytman [Thu, 26 Apr 2018 23:44:33 +0000 (02:44 +0300)]
Feat: Run set-commit-date-recursive on clone/fork

6 years agoFeat(git-status.sh): Use `git rev-parse` to find git dir
Oleg Broytman [Fri, 13 Apr 2018 16:37:27 +0000 (19:37 +0300)]
Feat(git-status.sh): Use `git rev-parse` to find git dir

6 years agoFeat: Limit memory for gc/repack
Oleg Broytman [Thu, 15 Mar 2018 02:27:52 +0000 (05:27 +0300)]
Feat: Limit memory for gc/repack

Add a script to set config to limit memory for gc/repack
to avoid out of memory errors.

6 years agoFix: No need to run `git repack`
Oleg Broytman [Thu, 15 Mar 2018 02:20:56 +0000 (05:20 +0300)]
Fix: No need to run `git repack`

`git gc --aggressive` runs `git repack` -A -d -l -f.

6 years agoFix(.gitignore): locate-all.list can only be in the root
Oleg Broytman [Tue, 13 Mar 2018 22:41:07 +0000 (01:41 +0300)]
Fix(.gitignore): locate-all.list can only be in the root

6 years agoFeat(ls-assumed): Recognize files with skip-worktree bit
Oleg Broytman [Fri, 9 Mar 2018 22:07:28 +0000 (01:07 +0300)]
Feat(ls-assumed): Recognize files with skip-worktree bit

Recognize files with `git update-index --skip-worktree`
in addition to `--assume-unchanged`.

6 years agoFeat: Script to fix .git/config executable bits
Oleg Broytman [Fri, 2 Mar 2018 07:59:04 +0000 (10:59 +0300)]
Feat: Script to fix .git/config executable bits

6 years agoFeat: Add a script to update .git/hooks/*.sample
Oleg Broytman [Fri, 2 Mar 2018 07:58:15 +0000 (10:58 +0300)]
Feat: Add a script to update .git/hooks/*.sample

6 years agoFix: Run chmod only after clone
Oleg Broytman [Fri, 2 Mar 2018 07:53:32 +0000 (10:53 +0300)]
Fix: Run chmod only after clone

6 years agoFeat(submodule): Test .gitmodules before running `git submodule`
Oleg Broytman [Mon, 26 Feb 2018 19:48:29 +0000 (22:48 +0300)]
Feat(submodule): Test .gitmodules  before running `git submodule`

6 years agoFeat(status): Copy index and set GIT_INDEX_FILE to avoid touching .git
Oleg Broytman [Mon, 26 Feb 2018 19:05:00 +0000 (22:05 +0300)]
Feat(status): Copy index and set GIT_INDEX_FILE to avoid touching .git

6 years agoAdd gc-expire scripts
Oleg Broytman [Sat, 3 Feb 2018 03:30:05 +0000 (06:30 +0300)]
Add gc-expire scripts

6 years agoRename gc-and-repack -> gc-repack
Oleg Broytman [Sat, 3 Feb 2018 03:26:44 +0000 (06:26 +0300)]
Rename gc-and-repack -> gc-repack

6 years agoFeat: Split git-open into git-open-remote
Oleg Broytman [Wed, 13 Dec 2017 19:35:17 +0000 (22:35 +0300)]
Feat: Split git-open into git-open-remote

git-open can now open any config key.
git-open-remote opens remotes URLs.

6 years agoFeat(locate-all): Case-sensitive sort
Oleg Broytman [Wed, 13 Dec 2017 12:15:32 +0000 (15:15 +0300)]
Feat(locate-all): Case-sensitive sort

7 years agoFix(fork): Add remote origin if it doesn't exist in an existing repo
Oleg Broytman [Fri, 27 Oct 2017 00:50:13 +0000 (03:50 +0300)]
Fix(fork): Add remote origin if it doesn't exist in an existing repo

7 years agoFix(fork): Do not add the existing repo to locate-all.list
Oleg Broytman [Fri, 27 Oct 2017 00:48:17 +0000 (03:48 +0300)]
Fix(fork): Do not add the existing repo to locate-all.list

7 years agoFeat: Add `clone` script
Oleg Broytman [Wed, 11 Oct 2017 21:56:56 +0000 (00:56 +0300)]
Feat: Add `clone` script

7 years agoFeat(fork): Check .git in the current directory
Oleg Broytman [Wed, 11 Oct 2017 21:47:50 +0000 (00:47 +0300)]
Feat(fork): Check .git in the current directory

7 years agoFeat(git-open): Get remote from the current branch
Oleg Broytman [Sun, 20 Aug 2017 21:01:32 +0000 (00:01 +0300)]
Feat(git-open): Get remote from the current branch

7 years agoMerge fork-existing into fork
Oleg Broytman [Sat, 19 Aug 2017 19:08:33 +0000 (22:08 +0300)]
Merge fork-existing into fork

7 years agoAdd fork-existing
Oleg Broytman [Tue, 30 May 2017 14:23:23 +0000 (17:23 +0300)]
Add fork-existing

7 years agoRemove scripts for manipulating projects
Oleg Broytman [Sat, 29 Apr 2017 22:26:33 +0000 (01:26 +0300)]
Remove scripts for manipulating projects

Moved to cookiecutter repo.

7 years agoRename update -> update-remotes
Oleg Broytman [Mon, 17 Apr 2017 19:57:15 +0000 (22:57 +0300)]
Rename update -> update-remotes

7 years agoFix publish2web: put the real web directory to locate-all.list
Oleg Broytman [Sat, 15 Apr 2017 23:17:41 +0000 (02:17 +0300)]
Fix publish2web: put the real web directory to locate-all.list

`pwd` was ~/tmp there.

7 years agoAdd cloned repository to the list of repos to process
Oleg Broytman [Tue, 11 Apr 2017 20:16:47 +0000 (23:16 +0300)]
Add cloned repository to the list of repos to process

7 years agoAdapt set-commit-date.py to Python 3: turn on universal_newlines
Oleg Broytman [Sun, 9 Apr 2017 01:21:40 +0000 (04:21 +0300)]
Adapt set-commit-date.py to Python 3: turn on universal_newlines

7 years agoUse `git branch --verbose` instead of `git status --branch`
Oleg Broytman [Sun, 19 Mar 2017 18:44:14 +0000 (21:44 +0300)]
Use `git branch --verbose` instead of `git status --branch`

Remove ls-not-pushed-carefully - it's no longer needed
as ls-not-pushed doesn't call `git status` anymore.

7 years agoIgnore archive/cheetah3 - it's a mirror of current/cheetah3
Oleg Broytman [Thu, 16 Mar 2017 23:28:40 +0000 (02:28 +0300)]
Ignore archive/cheetah3 - it's a mirror of current/cheetah3

7 years agoFix recursive gc/repack/fsck
Oleg Broytman [Sat, 11 Mar 2017 19:03:36 +0000 (22:03 +0300)]
Fix recursive gc/repack/fsck

7 years agoTest dirty status or not pushed state
Oleg Broytman [Mon, 9 Jan 2017 17:06:51 +0000 (20:06 +0300)]
Test dirty status or not pushed state

7 years agoTest status only in repos with worktrees
Oleg Broytman [Mon, 9 Jan 2017 17:03:34 +0000 (20:03 +0300)]
Test status only in repos with worktrees

7 years agoFix base directory name: do not remove .git suffix
Oleg Broytman [Mon, 9 Jan 2017 16:57:39 +0000 (19:57 +0300)]
Fix base directory name: do not remove .git suffix

7 years agoTest grep error code, not output
Oleg Broytman [Mon, 9 Jan 2017 16:31:10 +0000 (19:31 +0300)]
Test grep error code, not output

7 years agoAdd `fork` script to setup upstream and origin remotes
Oleg Broytman [Tue, 20 Dec 2016 19:15:11 +0000 (22:15 +0300)]
Add `fork` script to setup upstream and origin remotes

7 years agoUse xargs -I%
Oleg Broytman [Fri, 16 Dec 2016 18:36:04 +0000 (21:36 +0300)]
Use xargs -I%

7 years agoRename source -> upstream
Oleg Broytman [Sun, 11 Dec 2016 13:06:04 +0000 (16:06 +0300)]
Rename source -> upstream

8 years agoDo not pack submodules in bare repos
Oleg Broytman [Fri, 11 Nov 2016 15:00:49 +0000 (18:00 +0300)]
Do not pack submodules in bare repos

8 years agoAdd a script to list repos with assumed unchanged files
Oleg Broytman [Wed, 9 Nov 2016 17:11:19 +0000 (20:11 +0300)]
Add a script to list repos with assumed unchanged files

8 years agoRun git gc/repack/fsck recursively (on submodules)
Oleg Broytman [Sun, 6 Nov 2016 13:03:21 +0000 (16:03 +0300)]
Run git gc/repack/fsck recursively (on submodules)

8 years agoUse `git count-objects` instead of `find`
Oleg Broytman [Sun, 6 Nov 2016 11:47:46 +0000 (14:47 +0300)]
Use `git count-objects` instead of `find`

Count loose objects in submodules.

8 years agopull-usrlocalsrc: pull from source, push to origin
Oleg Broytman [Wed, 2 Nov 2016 19:53:04 +0000 (22:53 +0300)]
pull-usrlocalsrc: pull from source, push to origin

8 years agopull-usrlocalsrc: add git-remote-hg to PATH
Oleg Broytman [Wed, 2 Nov 2016 19:52:23 +0000 (22:52 +0300)]
pull-usrlocalsrc: add git-remote-hg to PATH

8 years agoAdd all-status all-status-carefully
Oleg Broytman [Fri, 14 Oct 2016 22:15:22 +0000 (01:15 +0300)]
Add all-status all-status-carefully

8 years agoCreate tmp dir in advance; set trap to remove it
Oleg Broytman [Fri, 14 Oct 2016 22:12:31 +0000 (01:12 +0300)]
Create tmp dir in advance; set trap to remove it

8 years agoFix `while read`; report non-existing directories
Oleg Broytman [Fri, 14 Oct 2016 22:11:22 +0000 (01:11 +0300)]
Fix `while read`; report non-existing directories

8 years agoMinor refactoring: first echo then slow rsync
Oleg Broytman [Fri, 14 Oct 2016 21:18:46 +0000 (00:18 +0300)]
Minor refactoring: first echo then slow rsync

Rename LSTMP -> STMP (it's not a tmp for ls).

8 years agopull-usrlocalsrc: pull only master from all remotes
Oleg Broytman [Fri, 7 Oct 2016 13:09:02 +0000 (16:09 +0300)]
pull-usrlocalsrc: pull only master from all remotes

8 years agoFix `while read`
Oleg Broytman [Fri, 7 Oct 2016 13:08:18 +0000 (16:08 +0300)]
Fix `while read`

8 years agoExclude .tox/ virtual environments when compiling byte code
Oleg Broytman [Sat, 24 Sep 2016 18:06:15 +0000 (21:06 +0300)]
Exclude .tox/ virtual environments when compiling byte code

8 years agoUse `git var GIT_EDITOR` to call editor
Oleg Broytman [Thu, 4 Aug 2016 23:44:29 +0000 (02:44 +0300)]
Use `git var GIT_EDITOR` to call editor

`git var GIT_EDITOR` is better than ${VISUAL:-${EDITOR:-vi}} because
it takes into account all variables: GIT_EDITOR, VISUAL and EDITOR,
and falls back to the platform's default.

8 years agoFix copy/paste bug
Oleg Broytman [Wed, 3 Aug 2016 12:29:25 +0000 (15:29 +0300)]
Fix copy/paste bug

8 years agoExclude empty "others" directories
Oleg Broytman [Wed, 3 Aug 2016 12:27:04 +0000 (15:27 +0300)]
Exclude empty "others" directories

8 years agoUse git status --branch --short
Oleg Broytman [Wed, 3 Aug 2016 12:18:48 +0000 (15:18 +0300)]
Use git status --branch --short

8 years agoUse new ls-dirty
Oleg Broytman [Wed, 3 Aug 2016 12:14:50 +0000 (15:14 +0300)]
Use new ls-dirty

This makes status-dirty-carefully much faster.

8 years agoUse git ls-files instead of status to avoid touching .git/
Oleg Broytman [Wed, 3 Aug 2016 12:14:10 +0000 (15:14 +0300)]
Use git ls-files instead of status to avoid touching .git/

8 years agoRename ls-dirty-carefully to ls-status-carefully
Oleg Broytman [Wed, 3 Aug 2016 12:12:36 +0000 (15:12 +0300)]
Rename ls-dirty-carefully to ls-status-carefully

Change variable $PROG_DIR => $prog_dir. Use long option.

8 years agoUse long option
Oleg Broytman [Wed, 3 Aug 2016 12:10:30 +0000 (15:10 +0300)]
Use long option

8 years agoChange local variable $PROG_DIR => $prog_dir
Oleg Broytman [Wed, 3 Aug 2016 12:09:39 +0000 (15:09 +0300)]
Change local variable $PROG_DIR => $prog_dir