Code Monkey home page Code Monkey logo

git-series's Introduction

git series tracks changes to a patch series over time. git series also tracks a cover letter for the patch series, formats the series for email, and prepares pull requests.

Manpage for git-series

About git-series

A patch series typically goes through multiple iterations before submission; the path from idea to RFC to [PATCHv12 1/8] includes many invocations of git rebase -i. However, while Git tracks and organizes commits quite well, it doesn't actually track changes to a patch series at all, outside of the ephemeral reflog. This makes it a challenge to collaborate on a patch series, distribution package, backport, or any other development process that includes rebasing or non-fast-forward development.

Typically, tracking the evolution of a patch series over time involves moving part of the version control outside of git. You can move the patch series from git into quilt or a distribution package, and then version the patch files with git, losing the power of git's tools. Or, you can keep the patch series in git, and version it via multiple named branches; however, names like feature-v2, feature-v3-typofix, and feature-v8-rebased-4.6-alice-fix sound like filenames from corporate email, not modern version control. And either way, git doesn't track your cover letter at all.

git-series tracks both a patch series and its evolution within the same git repository. git-series works entirely with existing git features, allowing git to push and pull a series to any git repository along with other branches and tags. git-series also tracks a cover letter for the patch series, formats the series for email, and prepares pull requests.

As you change a patch series, git-series can show diffs between versions, finding and showing the correspondence between the old and new versions of each commit, even after changing or rebasing those commits. The series diff format shows corresponding old and new commits side-by-side, with interdiffs for modified commits. (This is similar to the git range-diff format.)

Building and installing

git-series is written in Rust. You'll need both Rust and Cargo installed to build it. If your OS distribution includes packages for Rust and Cargo, start by installing those (for instance, on Debian, apt install rustc cargo). If your distribution doesn't have packages of Rust and Cargo, or has an outdated version (which may result in build errors), you can download the stable version of Rust and Cargo from the rust-lang.org download page.

With Rust and Cargo installed, you can download and install the latest release of git-series with:

cargo install --root ~/.local git-series

This will install git-series into ~/.local/bin/git-series. If you don't already have ~/.local/bin on your $PATH, you may want to add it there, or change the --root. You may also want to install the included manpage, git-series.1, into ~/.local/share/man/man1/git-series.1.

If you'd like to package git-series for your distribution, please contact me.

Overview of commands

  • Use git series start seriesname to start a patch series seriesname.

  • Use git series base somecommit to set the base commit for the series. (This is the upstream commit you based the series on, not the first patch in the series.)

  • Use normal git commands to commit changes.

  • Use git series rebase -i to help rework or reorganize the patch series.

  • Use git series status to check what has changed.

  • Use git series diff to show the changes to the patch series as a diff.

  • Use git series cover to add or edit a cover letter.

  • Use git series add and git series commit (or git series commit -a) to commit changes to the patch series. You can do this whenever you've changed the base or cover letter, or whenever you've changed HEAD to a new commit. Make a series commit whenever you've made a semantic change to the patch series that you want to record, such as rebasing on a new upstream version, reorganizing patches, or incorporating feedback.

  • Use git series format to prepare the patch series to send via email, or use git series req to prepare a "please pull" mail (after pushing the changes to a repository as a branch or tag).

Workflow example

Suppose you want to write a patch series implementing a new feature for a project. You already have a local git clone of the repository. You could start a branch for this patch series, but it may take multiple iterations before upstream accepts it, and you may need to use rebase or amend to fix commits; a branch can't track that. With git-series, you'll develop the patch series as you normally would, including rebases, and periodically git series commit the state of the patch series, complete with a commit message explaining what you've changed. Even if you rebase the patch series, or make some other change that doesn't fast-forward, git-series will track those changes with a branch that does fast-forward, so you can easily share and review the history of your patch series.

Developing or importing the first version

To start the patch series, first run git series start featurename. featurename here specifies the name for the series, just as you'd specify the name of a branch.

A patch series needs some base to build on, identifying the upstream commit you want to develop from. This will become the parent of the first patch in your series. If you want to base your patch series on the current version, run git series base HEAD. If you want to base this patch series on some other commit, such as a released version, first check out that commit with git checkout thecommit, then run git series base HEAD.

You can then develop the patch series as usual, committing patches with git.

If you've already started on the patch series and made some commits, you can still adopt the current version of the patch series into git-series. Find the parent commit of the first patch in your series, and run git series base thatcommit.

As with git, you can run git series status at any time to see the current state of the series, including changes you might want to commit, and the next step to run. After the above steps, git series status should show base and series modified; running git series base set the base in the "working" version, and series in the working version always refers to HEAD (the current git commit you have checked out).

Now that you've written an initial version of the patch series (or you already wrote it before you started using git-series), you can commit that version to git-series. Run git series commit -a to commit the series. This will run your editor so you can provide a series commit message (e.g. "Initial version of feature" or "Import feature into git-series").

If your patch series include multiple patches, you may want to add a cover letter. Run git series cover to edit the cover letter, then git series commit -a -m 'Add cover letter' to commit that change to the series.

Now that you have the first version of the patch series, you can format it as a series of emails with git series format.

Developing v2

You send the patch series by email, and you get feedback from the maintainers: the concept looks good, but you need to split one of the patches into two, and add benchmark results in another commit's commit message.

Run git series rebase -i, and split the commit (mark it for 'e'dit, git reset -N HEAD^, repeatedly git add -p and git commit, then git rebase --continue). Then, commit that change to the series: git series commit -a -m 'Split out X change into a separate patch'

Then, run git series rebase -i again to add the benchmark results (mark the commit for 'r'eword), and commit that change: git series commit -a -m 'Add benchmark results'.

You may want to document the changes in the cover letter: run git series cover, document the changes, and git series commit -a -m 'Update cover letter for v2'. (Alternatively, you can incrementally add to the cover letter along with each change to the series.)

Now that you have v2 of the patch series, you can format it as a new series of emails with git series format -v 2.

git-series's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

git-series's Issues

an indication that a series has been merged

Often times I have a series that gets posted on a ML and it will take upstream a while to land it or I just never get around to cleaning things up until I get back to the project. Prior to git-series I would go into that branch and rebase it onto the latest master and see there were no changes between it and master with something like git branch --merged. With git series I wanted to do something similar but the only indication I seem to have of this state is the following:

╭─cardoe@swanson  ~/work/xen/xen  ‹(904f931...)*›
╰─$ git series format                                                     139 ↵
error: git-series died of signal 11

Similar output for git series diff as well.

I'm on version 0.9.1

Support import of patch series

Add a command to import a patch series from a series of files, and make it the next version of a series (or a new series). In addition to simplifying the process of turning a format-patched series into a git-series commit, this would also enable advanced workflows like "export series as patches, run sed, re-import series, git series commit".

Import should also support setting the baseline in the same step, to allow this rebase workflow:

  • Export all patches
  • Run sed on all patches to rename variable that was renamed upstream
  • git series import -b new-upstream patches
  • git series diff to review
  • git series commit

Support bisecting the patch series

git-series should support bisecting over versions of the patch series. git bisect could run on a git-series/* ref, but that wouldn't check out the series itself for testing.

This needs some combination of additional tooling and documentation.

sequence.editor / GIT_SEQUENCE_EDITOR not respected by git-series

It is useful to be able to set a script for GIT_EDITOR, this require use of the
GIT_SEQUENCE_EDITOR variable or the sequence.editor config setting to avoid the script from overriding the editor also on the rebase -i commit sequence.

git-series seems to ignore these settings.

req: Detect working version changes and warn

If the working version of the series has changes compared to the committed version, and the user pushed the working version somewhere to request a pull of, git series req should detect this case and warn that the user may want to commit or (once it exists) operate on the working version.

git-series format emitting hundreds of commits for a 5 patch series

I suspect it's related to changing the commit base due to a rebase -- I'm adopting an existing patch series into git-series, including changes to the series, by doing a reset --hard to each topic branch over time and then git-series commit'ing each, but the base changes too since the different topic branches were rebased over time as well. There are only 5 commits between the current series base and HEAD.

Initialise new series with an empty commit

What if git-series initialised all new series with an "initial" commit? Ie. one with no parents, the empty tree, and some default message. This gives us the property that the series commit is always the second parent.

The purpose is to make "git-series/" branches a bit easier to work with when git-series isn't installed. For instance, you could do a pretty decent imitation of git series log with git log --merges --first-parent git-series/<series>.

Is it too late for this?

Better diffs of base and series

Currently, the diffs of series and base shown in git series log -p just show the old and new commit hashes. The diff for base should include the commit summary for both commits, and possibly decorations. The diff of series should show some useful summary of how the patch series has changed.

Potentially useful information for diffs of series:

  • Diff of a list of patch subjects (git log --oneline output without the hashes). Useful to see patch reorganization.
  • Diff of full commit messages.
  • Diff of full commits with patches included, with rename detection turned on to notice patch reordering. (Helpful if you don't mind reading diffs-of-diffs.)
  • Overall diff of final git trees. (For instance, when refactoring or rebasing patches, it helps to know what has changed in the whole series. Less useful if you've rebased the series.)
  • Something like git-cherry. This depends on patch-id, though, which changes when the patch changes at all.

Based on discussions with users, the default will be diffs of full commits with patches included. There will also be a second option to provide the overall diff of the final git trees.

git series cover could show commented shortlog and diffstat

I often find it useful to be reminded of the shortlog and diffstat while writing a cover letter, which git format-patch --cover-letter automatically adds to the cover letter. It'd be handy if "git series cover" could add that same information commented out below the cover letter so it can be easily referred to.

Add git series send-email

git series send-email could wrap the regular git send-email but add support like versioned recipients, and keeping track of version numbers etc.

git series format doesn't declare a Content-Transfer-Encoding

If the commit has certain characters (e.g. č, á, ř), git format-patch would add:
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

but git series format doesn't add these, so git send-email complains:
0000-cover-letter.patch
...
The following files are 8bit, but do not declare a Content-Transfer-Encoding.
0000-cover-letter.patch
...
Which 8bit encoding should I declare [UTF-8]?

It'd be nice if git series format took care of that.

Per commit changelog in format output

Currently git series format does not output a changelog with each patch.

When changes have been commited to git series, I see no reasons why a changelog based on the git series commit messages could not be generated when running git series format.
Maintaining that changlog would increase the utility of this tool a lot.

[COMMIT MESSAGE]

---
Changes since v1:
 - Added function x()
 - Removed memcpy
 - Fixed whitespace issue

 changed_file.c   |  66 +++++

diff --git a/include/linux/cgroup_rdma.h b/include/linux/cgroup_rdma.h
new file mode 100644
index 0000000..6710e28
--- /dev/null
+++ b/changed_file.c
[PATCH CONTENT]

git series rebase -i gives: no such file or directory error on file rebased-merge/stopped-sha

I just did a git series rebase -i to pull 3 patches from the series and everything appears to be working fine, but I get the following message on the console:

<ebase-merge.eqRWLxvVEHIe/git-rebase-todo" 31L, 1663C written
Checking out files: 5/5
cat: /home/kershnda/kernel/master/unisys/.git/rebase-merge/stopped-sha: No such file or directory
Successfully rebased and updated detached HEAD.

Not sure what that message is trying to tell me.

Add leading zeros to the Patch series in the Subject line

I just got the following feedback back from gregkh:

The purpose of this patch is to add style consistency and beautify the
entire file.

Grammar:
Uppercased beginning of new sentences/paragraphs
Missing ' and .
Fixed several comments using prefix phrase "as is in" to "as in"
Standard Grammar

Comments:
Fixed comments to follow the multiline styling
All comments are now either same line or above variable/definitions
Removed nested slash-star comments
Removed a random comment left by accident
Aligned star comments

Signed-off-by: Erik Arfvidson [email protected]
Signed-off-by: David Kershner [email protected]

How did you create these emails? git format-patch should have put a
leading 0 on the [PATCH 1/14], to make it so that things can be sorted
properly and I can apply them in the correct order.

Please fix up and resend this series.

thanks,

greg k-h

I think I found the line, but I'm not sure how to add changes unless I push my own git repo and then pull from that.

series creation quietly defaults to "baseless" series

git series has (at least) two main use cases: with or without a "base".

"Baseless" gitseries cater for non-forwarding branches with "volatile" commits regularly force-pushed. For instance integration branches re-merging other branches every night like for instance linux-next, drm-tip - basically any place where a large number of awkward foo-YYYYMMDD git refs can be seen.

"Baseless" gitseries are probably a less common use case and they offer less features than with a base. Yet starting a series doesn't set any default base (HEAD?) and doesn't remind to set one. It doesn't provide any --base option either. Long story short the default behaviour leads the naive and/or distracted user towards the feature he or she is likely NOT interested in and then confusion ensues.

While I haven't performed a very thorough review, README.md doesn't seem to mention baseless gitseries at all. It seems to merely request the user "not to forget" to set a base so maybe there's room for documentation improvements too.

Add `git series merge`

I've found the following alias useful. It merges the given series into HEAD, pre-populating the merge text with the cover message.

series-merge = !"f() { git merge git-series/$1:series --edit -m \"$(git show git-series/$1:cover)\"; }; f"

Perhaps it would be nice to move this functionality into git-series?

Provide bash-completion support

Support tab-completing references to series names, git revisions, subcommand names, and options.

The clap argument parser can help generate this, but it doesn't support extending its generated completions with specific types of things to complete, such as series names or git revisions. See clap-rs/clap#568

Support invoking gitk on the series

Support spawning gitk with the range base..series.

Also, submit patches to upstream gitk (and git rev-list) to support viewing the history of a patch series.

include a brief tutorial

Very nice project! I'm really interested in giving it a try, and it would be super useful to have a brief tutorial in addition to the command descriptions in the README. I think I can kind of understand how to use the tool from the README, but if there were a walkthrough that used real data and a specific sequence of commands, that would dramatically increase my confidence that I understand what the tool is doing.

Another thing that might be useful is to describe what each command does. The README states, for example, that this reuses existing git functionality. If I weren't to use git series, how would I re-create the workflow without it? (I don't mean this as a way to work around git series, but rather, as a way to understand it in terms of something that I already understand.)

git series base and rebase don't accept tags

git series base and git series rebase unobviously refuse to accept tag names, e.g.

$ git series base v4.8-rc1
[3/-1] Object is no commit object

$ git series base 29b4817d4018
Previous base was ...
Set patch series base to 29b4817d4018 Linux 4.8-rc1

and for rebase:

$ git series rebase v4.8-rc1
[3/-3] The requested type does not match the type in ODB

$ git series rebase 29b4817d4018
Checking out files: 11433/11433
Executing: git series base 29b4817d4018df78086157ea3a55c1d9424a7cfc
Previous base was ...
Set patch series base to 29b4817d4018 Linux 4.8-rc1
Successfully rebased and updated detached HEAD.

Support rebase --exec

There are many options taken by git rebase which continue to make sense in the context of a git series rebase. I'm not sure whether it's worth reimplementing all of them, but the --exec flag in particular should be easy to implement and is, in my experience, quite useful.

"git --git-dir=/some/other/repository/.git series" doesn't find .git

Most git commands you can provide a --git-dir argument after git and before the command, and you can run it from a directory outside of the git working directory. Git series however doesn't seem to work like this. Is it possible to make it pick up that --git-dir?

$ git --git-dir=/path/to/linux/.git series format
[6/-3] Could not find repository from '.'

The same thing happens when setting GIT_DIR environment variable (which I presume is how git implements --git-dir internally anyway).

Support amending patch series

Unless I missed something, once you've made a new git-series commit, it's fixed in stone and cannot be amended (at least, not via git series - I assume it's possible to do it manually with normal git commands by using knowledge of the internals of git-series). Here are some examples of use cases where the ability to amend the history of the series would be useful:

  • Amend the commit message of a git-series commit
  • Remove a git-series commit from the series history
  • Amend the base, series, or cover of a git-series commit (e.g. if you forgot to do this when first creating the commit)

fuil license missing

The cargo file says MIT, but I think that's a bit thin. Full MIT in LICENSE would be good I think, and maybe also at the top of each source file with copyright notices.

Support sub-series

Allow a series to contain several delineated sub-series. This could help for maintainers merging several patch series together, or for distribution packages that have both upstream patches and distribution packaging metadata, both of which have history.

format: include base-commit

git format-patch now has a --base option, which includes the base commit for the patch series in the cover letter or first patch. git series format should include this as well.

Support formatting the working or staged version of the series

git series format currently only supports running on the committed version of the series. You might want to preview what the formatted series would look like, so git series format should provide options to format the working and staged versions of the series. git series fomat should also detect a series with no commits yet, and suggest those options, rather than just failing.

diff: Allow diffing between arbitrary revisions

(This issue overlaps with #5.)

It would be nice to be able to see the diff between two revisions of a series.

git series diff                        = git series diff SHEAD "working series"
git series diff <commit>               = git series diff <commit> "working series"
git series diff <commit> <commit>

It's possible to mimic some of git diff's range-syntax forms as well (ie. <commit>..<commit>, <commit>.., and ..<commit>); I'm not sure it's a good idea though. We're not really talking about ranges here...

display only a subset of the {subject,message,source} diff

Some projects/tools require inlining "decoration" (metadata) in commit messages, for example Gerrit Change-Ids or this:
https://www.chromium.org/chromium-os/how-tos-and-troubleshooting/kernel-faq#TOC-Remove-Chromium-OS-specific-Details

Work with commits from/to these projects has (at least) two very distinct phases:

  1. review source differences
  2. review commit messages "decorations"

So it would be useful if "git series diff", "git series log -p" etc. could focus on an arbitrary subset of the {subject,message,source} diff.

Failing to build: custom build command for openssl-sys fails

I am trying to build this program with cargo build, but I get an error
which seems to be coming from the package openssl-sys, version 0.9.1.

Steps to reproduce

Executed with Rustc version 1.12.0 and Cargo version 0.13.0 in shell
nix-shell --pure -p rustStable.rustc -p rustStable.cargo -p git.

  • OS: Ubuntu 14.04
$ git checkout 0.9.1
$ cargo --version
cargo 0.13.0 (built 2016-10-21)
$ rustc --version
rustc 1.12.0
$ RUST_BACKTRACE=1 cargo build
   Compiling openssl-sys v0.9.1
   Compiling num v0.1.36
Build failed, waiting for other jobs to finish...
error: failed to run custom build command for `openssl-sys v0.9.1`
process didn't exit successfully: `<path>/git-and-tools/git-series/repo/git-series/target/debug/build/openssl-sys-76c1fa79ef1208aa/build-script-build` (exit code: 101)
--- stderr
thread 'main' panicked at '

Could not find directory of OpenSSL installation, and this `-sys` crate cannot
proceed without this knowledge. If OpenSSL is installed and this crate had
trouble finding it,  you can set the `OPENSSL_DIR` environment variable for the
compilation process.

If you're in a situation where you think the directory *should* be found
automatically, please open a bug at https://github.com/sfackler/rust-openssl
and include information about your system as well as this message.

    $HOST = x86_64-unknown-linux-gnu
    $TARGET = x86_64-unknown-linux-gnu
    openssl-sys = 0.9.1


It looks like you're compiling on Linux and also targeting Linux. Currently this
requires the `pkg-config` utility to find OpenSSL but unfortunately `pkg-config`
could not be found. If you have OpenSSL installed you can likely fix this by
installing `pkg-config`.

', <home>/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-sys-0.9.1/build.rs:142
stack backtrace:
   1:     0x563b41d65f0b - std::sys::backtrace::tracing::imp::write::h00e948915d1e4c72
   2:     0x563b41d6cddf - std::panicking::default_hook::_{{closure}}::h7b8a142818383fb8
   3:     0x563b41d6c025 - std::panicking::default_hook::h41cf296f654245d7
   4:     0x563b41d6c6e5 - std::panicking::rust_panic_with_hook::h4cbd7ca63ce1aee9
   5:     0x563b41d28d76 - std::panicking::begin_panic::h93672d0313d5e8e9
                        at /tmp/nix-build-rustc-1.12.0.drv-0/rust-3191fba/src/libstd/panicking.rs:384
   6:     0x563b41d416fb - build_script_build::find_openssl_dir::hb68e52b7bbb3a4dd
                        at <home>/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-sys-0.9.1/build.rs:3
   7:     0x563b41d43688 - build_script_build::main::_{{closure}}::h3e9f4699862f6d52
                        at <home>/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-sys-0.9.1/build.rs:15
   8:     0x563b41d23d80 - _<core..option..Option<T>>::unwrap_or_else::heb656dab87effcd3
                        at /tmp/nix-build-rustc-1.12.0.drv-0/rust-3191fba/src/libcore/option.rs:361
   9:     0x563b41d400e9 - build_script_build::main::h73ab0570d224c5dd
                        at <home>/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-sys-0.9.1/build.rs:14
  10:     0x563b41d72c76 - __rust_maybe_catch_panic
  11:     0x563b41d6ba39 - std::rt::lang_start::h53bf99b0829cc03c
  12:     0x563b41d447a3 - main
  13:     0x7fc3caf3c2df - __libc_start_main
  14:     0x563b41d20769 - _start
                        at ../sysdeps/x86_64/start.S:120
  15:                0x0 - <unknown>

usage question: How do I abandon changes to the cover

I've made changes to a cover letter and just want to abandon them, normally with git I would do git checkout -- file to undo the changes, I tried git series cover --, but that didn't work, so wondering what the syntax would be.

refs/SHEAD is dangling when new series is created without any commits

It seems that if I create a new series but don't commit it, I get a lot of "warning: ignoring broken ref refs/SHEAD"/"warning: symbolic ref is dangling: refs/SHEAD" all over the place.

Trivial repro case:

ajd@ajd:~/tmp$ git init broken-ref-shead
Initialized empty Git repository in /home/ajd/tmp/broken-ref-shead/.git/
ajd@ajd:~/tmp$ cd broken-ref-shead/
ajd@ajd:~/tmp/broken-ref-shead$ touch banana
ajd@ajd:~/tmp/broken-ref-shead$ git add banana; git commit -asm "initial commit"
[master (root-commit) eb562b1] initial commit
 1 file changed, 0 insertions(+), 0 deletions(-)
 create mode 100644 banana
ajd@ajd:~/tmp/broken-ref-shead$ git series start bananas
ajd@ajd:~/tmp/broken-ref-shead$ git branch <TAB>warning: ignoring broken ref refs/SHEAD
ajd@ajd:~/tmp/broken-ref-shead$ git gc
Counting objects: 7, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (7/7), done.
Total 7 (delta 1), reused 0 (delta 0)
warning: symbolic ref is dangling: refs/SHEAD

As soon as I run "git series commit" and make a commit to the series, the problem disappears.

Highlight trailing whitespace

git-series should detect and highlight trailing whitespace the way git does. (That includes respecting git's many different bits of configuration for that.)

cargo cannot install clap

Am I doing something wrong? This is a Debian/stretch box:

% cargo install --root ~/.local git-series

    Updating registry `https://github.com/rust-lang/crates.io-index`
   Compiling bitflags v0.7.0
   Compiling vec_map v0.6.0
   Compiling bitflags v0.1.1
   Compiling ansi_term v0.8.0
   Compiling quick-error v1.1.0
   Compiling gcc v0.3.37
   Compiling colorparse v1.1.0
   Compiling num-traits v0.1.36
   Compiling ansi_term v0.9.0
   Compiling unicode-normalization v0.1.2
   Compiling unicode-width v0.1.3
   Compiling pkg-config v0.3.8
   Compiling libz-sys v1.0.6
   Compiling openssl-sys v0.7.17
   Compiling unicode-segmentation v0.1.2
   Compiling num-integer v0.1.32
   Compiling winapi-build v0.1.1
   Compiling kernel32-sys v0.2.2
   Compiling strsim v0.5.1
   Compiling matches v0.1.3
   Compiling unicode-bidi v0.2.3
   Compiling idna v0.1.0
   Compiling url v1.2.1
   Compiling winapi v0.2.8
   Compiling libc v0.2.17
   Compiling rand v0.3.14
   Compiling time v0.1.35
   Compiling term_size v0.2.1
   Compiling clap v2.14.0
.cargo/registry/src/github.com-1ecc6299db9ec823/clap-2.14.0/src/errors.rs:857:35: 857:46 error: no method named `description` found for type `std::fmt::Error` in the current scope
.cargo/registry/src/github.com-1ecc6299db9ec823/clap-2.14.0/src/errors.rs:857         Error::with_description(e.description(), ErrorKind::Format)
                                                                                                                ^~~~~~~~~~~
error: aborting due to previous error
error: failed to compile `git-series v0.8.10`, intermediate artifacts can be found at `/tmp/brian/cargo-install.hSw3fAyyTNbG`

Caused by:
  Could not compile `clap`.

To learn more, run the command again with --verbose.

cargo installation failure

Any ideas on how to debug this failed installation on openSUSE Leap 42.1? Thanks!

$ cargo -V
cargo 0.11.0
$ rustc -V
rustc 1.10.0-dev
$ cargo install --root ~/.local git-series
    Updating registry `https://github.com/rust-lang/crates.io-index`
 Downloading git-series v0.8.10
 Downloading tempdir v0.3.5
 Downloading colorparse v1.1.0
 Downloading clap v2.13.0
 Downloading quick-error v1.1.0
 Downloading ansi_term v0.8.0
 Downloading isatty v0.1.1
 Downloading chrono v0.2.25
 Downloading git2 v0.4.4
 Downloading rand v0.3.14
 Downloading libc v0.2.16
 Downloading vec_map v0.6.0
 Downloading unicode-segmentation v0.1.2
 Downloading unicode-width v0.1.3
 Downloading strsim v0.5.1
 Downloading bitflags v0.7.0
 Downloading term_size v0.2.1
 Downloading ansi_term v0.9.0
 Downloading num v0.1.35
 Downloading time v0.1.35
 Downloading num-iter v0.1.32
 Downloading num-traits v0.1.35
 Downloading num-integer v0.1.32
 Downloading kernel32-sys v0.2.2
 Downloading winapi v0.2.8
 Downloading winapi-build v0.1.1
 Downloading bitflags v0.1.1
 Downloading url v1.2.1
 Downloading libgit2-sys v0.4.5
 Downloading idna v0.1.0
 Downloading matches v0.1.2
 Downloading unicode-bidi v0.2.3
error: failed to compile `git-series v0.8.10`, intermediate artifacts can be found at `/tmp/cargo-install.VKC5fEzV0l4R`

Caused by:
  unable to get packages from source

To learn more, run the command again with --verbose.
$ cargo install --verbose --root ~/.local git-series
    Updating registry `https://github.com/rust-lang/crates.io-index`
error: [0/-1] an unknown error occurred
$ find /tmp/cargo-install.VKC5fEzV0l4R -ls
 32821    4 drwxr-xr-x   3 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R
    51    4 drwxr-xr-x   7 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release
    54    4 drwxr-xr-x   2 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release/native
    55    4 drwxr-xr-x   2 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release/.fingerprint
    52    0 -rw-r--r--   1 adam     users           0 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release/.cargo-lock
    57    4 drwxr-xr-x   2 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release/build
    56    4 drwxr-xr-x   2 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release/examples
    53    4 drwxr-xr-x   2 adam     users        4096 Sep 29 01:13 /tmp/cargo-install.VKC5fEzV0l4R/release/deps

Request: comparison to tools like Stacked Git in the readme

Since Git-series is a tool to manage a “patch series”, it might good to provide
some comparison with some other tool that tries to do the same — even if the
other tool might not be as geared towards the email-based “patch series”
workflow as Git-series is.

As of commit b5fd4af (“Release version 0.9.1”, 2016-11-21), the readme
mentions one patch management tool, namely Quilt:

Typically, tracking the evolution of a patch series over time involves moving
part of the version control outside of git. You can move the patch series from
git into quilt or a distribution package, and then version the patch files
with git, losing the power of git's tools. Or, you can keep the patch series
in git, and version it via multiple named branches; …

(Emphasis added.)

So one concern with Quilt is “losing the power of Git’s tools”. I don’t know if
Guilt solves this, but StGit (“Stacked Git”) is one of example of a tool
that integrates with Git; the patches are stored as Git commit objects, and the
metadata of the “patch series” is stored in the Git repository.

I haven’t yet tried Git-series (see issue #50), but as an imagined example of a
comparison based on my impressions:

  • Git-series has first-class support for tracking cover letters.
  • Git-series provides git series commit so that a change to the series can be
    explained, while StGit has no equivalent “series commit” (as far as I can
    tell).
  • StGit lets you undo and redo commands (like pushing or popping the applied
    patches), while Git-series .

If nothing else, if the tools are very dissimilar (in their use-cases), one can
dispell any possible confusion between tools like StGit and Git-series since
they both use the term “patch series”.

To be clear, though, StGit is just an example. Maybe some other tool is more
appropriate to compare with.

Doesn't work within git-worktrees

~/my-worktree$ git series checkout foobar
[6/-3] Could not find repository from '.'

I expect the problem here is mostly just #7, although there may be more to it.

Some context:

~/my-worktree$ git worktree list
/home/asayers/my-repo      [...]
/home/asayers/my-worktree  [...]
~/my-worktree$ git rev-parse --git-dir
/home/asayers/my-repo/.git/worktrees/my-worktree

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.