| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Rumor has it that sync-all is slowly on the way out. Now that all
subrepositories have been turned into git submodules, sync-all might
not be needed anymore. Nevertheless, here are some changes I had made
while trying to understand why it existed in the first place:
* update comments + help text
* rename some variables for maintainability
* s/branch_name/remote_name/
origin is the name of a remote, not a branch
* s/repo_base/remote_root/
the word *remote* is key here
* s/defaultrepo/default_root/
this was a darcsism, and it doesn't refer to a repository but to the
root directory of all repositories
* small tweaks
* .git can be a file nowadays
* don't skip END actions on exceptions #8886
reverts d523f9b3d4ce3463e8816cad2139ea397e00f8d1
Test Plan:
Why revert d523f9b3d4ce3463e8816cad2139ea397e00f8d1?
I put an old haddock repository from
http://darcs.haskell.org/haddock2.git back in my tree. Now, when running
`sync-all get`, the following happens:
1. I get a cryptic error saying:
fatal: reference is not a tree:
5412c262f403e52be45d607b34eb3a5806ea2a76
Unable to checkout '5412c262f403e52be45d607b34eb3a5806ea2a76' in
submodule path 'utils/haddock'
git failed: 256 at ./sync-all line 112.
2. sync-all checks if maybe an old haddock repository is present
3. I get a clear warning saying:
============================
ATTENTION!
You have an old haddock repository in your GHC tree!
Please remove it (e.g. "rm -r utils/haddock"), and then run
"./sync-all get" to get the new repository.
============================
Without commit d523f9b3d4ce3463e8816cad2139ea397e00f8d1 reverted, steps
2 and 3 were skipped. The problem that commit tried to solve,
is now solved with 7012ed8515100b4947383e93b82dbff7a0aa835c.
Reviewers: nomeata, austin, hvr
Reviewed By: austin, hvr
Subscribers: simonmar, ezyang, carter
Differential Revision: https://phabricator.haskell.org/D178
GHC Trac Issues: #8886, #9212
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes #8886.
Problem: any `sync-all` command that is run before the first succesfull
`sync-all get` would trigger a false warning about an old `time` package
being present.
Cause: after cloning the ghc repository, the (empty) `libraries/time`
directory is already present.
Solution: check if the directory actually contains any of the `time`
files. I picked the `LICENSE` file, since `boot` does so as well.
Signed-off-by: Austin Seipp <austin@well-typed.com>
|
| |
|
| |
|
|\
| |
| |
| | |
as submitted on #9212.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
After this commit, running `sync-all remote set-url` works properly for the
haddock package:
command: ./sync-all -r git://git.haskell.org remote set-url origin
before: git://git.haskell.org/packages/haddock.git
after: git://git.haskell.org/haddock.git
By doing the `remotepath` lookup before the `$is_github_repo` check,
running `sync-all remote set-url` now also works properly for submodule
repos on github:
command: ./sync-all -r git://github.com/ghc remote set-url origin
before: git://github.com/ghc/packages/binary
after: git://github.com/ghc/packages-binary
* Relevant prior commits:
4f4357 "Make `sync-all remote set-url` use normalized `/packages/` urls"
34b072 "Convert haddock into a proper submodule (re #8545)"
974a97 "sync-all: Apply submodule url rewriting also to stuff in util/"
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Not only does this make the code easier to read, it also fixes a bug.
Starting with commits 691c8a and ccce9f, certain subcommands should
behave differently for submodules. This was done by checking, for each
such subcommand:
$remotepath eq "-"
This commit corrects that to the check:
$$line{"remotepath"} eq "-".
Because when we have a clone of a local mirror (checked_out_tree=1),
remotepath actually gets set to $$line{"localpath"}.
|
| | |
|
| |
| |
| |
| |
| | |
Since commit 0e17d4, the default "tag" is "-", not "". It is never
undefined.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When running './sync-all get', 'git submodule init' has to be (and is
always) executed, since .gitmodules might contain new submodules (see
commit c3db2b). As a result, after cloning the ghc repo and running the
initial './sync-all get', .git/config will always contain some submodule
sections. Therefore it is not needed to check for this on every
subsequent get or pull, and this code can be deleted.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
+ Remove dead code from the DarcsAges
+ Tweak `git config` flags
* remove --local, it is not a valid flag
* --get was used in some places, not in others
+ Simplify reading current branch
+ Delete duplicated code in help
|
|/ |
|
|
|
|
| |
As suggested in #9057.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Curiously, 'aforesaid' has the same length as the word 'testsuite'...
Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adapts `sync-all` and `packages` to the recently folded-in Git
repositories
- `base.git`
- `ghc-prim.git`
- `integer-gmp.git`
- `integer-simple.git`
- `template-haskell.git`
See #8545 as well as 5f54d67818ee7a74325eed130438beba96510e43 for more
details.
Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
|
|
|
|
|
|
|
|
| |
Before this change, the END actions were executed even if the code
throws an exception using "die". This resulted in very confusing
error reporting when an invalid command line option was specified.
Signed-off-by: Austin Seipp <austin@well-typed.com>
|
| |
|
|
|
|
| |
This fixes #8824.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
See merge commit 66693401b98cb5aa912948af7bbd2182474f50c4
This commit also adds a check for a left-over testsuite/.git folder to sync-all
This way, the first time sync-all is called after updating to a
post-testsuite-merge (see #8545) state of ghc.git, the sync-all script
aborts with an error message if a `testsuite/.git` folder is detected and
thus forces the user to take action.
Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
|
| |
|
| |
|
|
|
|
|
|
|
| |
This applies attachment:sync-all-submodules-locally.diff from #8369
Authored-by: Nathaniel Filardo
Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
|
| |
|
| |
|
|
|
|
|
|
|
| |
By keeping the repository url in the `packages` file scripts such as
source:ghc/sync-all can pick it up. Moreover, it's easier to
automatically validate for correctness than the
wiki:Repositories/Upstream page.
|
|
|
|
|
|
|
|
| |
If the check detects an obsolete URL, show a warning and tell the user how
to invoke `sync-all` in order to update the local Git repo to point to the new
repository URLs.
This is related to #8121
|
|
|
|
|
|
| |
We weren't considering 'msys' for the $OSNAME.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
|
| |
This reverts commit 2e41f2fa91c833a4420ac273254e49468044bc4b.
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
|
| |
...as the new `git.haskell.org` CNAME has been activated
(see also GitolitePlan and #8121 for more details)
|
|
|
|
| |
Signed-off-by: Austin Seipp <aseipp@pobox.com>
|
|
|
|
| |
This is a test commit for addressing #8121
|
|
|
|
|
|
|
|
|
|
|
|
| |
A simple heuristic (i.e. replacing the `libraries/` suffix by
`packages/` in the inferred remotepath, if the remotepath in the
`packages` file is "-") used to infer the remotepath for Git
submodules. A proper solution would require to parse the `.gitmodules`
file to obtain the actual localpath<->remotepath mapping.
This addresses #8121 and is a follow-up to a22e908 which changed the
`.gitmodules` urls to use the `/packages/` folder instead of
`/libraries/`.
|
| |
|
| |
|
| |
|
|
|
|
| |
This means that ghc-tarballs is only needed on Windows
|
| |
|
| |
|
| |
|
|
|
|
| |
It's now always 'git'.
|
| |
|
|
|
|
| |
Apparently git ignores the --git-dir argument.
|
|
|
|
| |
Based on a patch from rassilon.
|
| |
|