| Age | Commit message (Collapse) | Author |
|
At present if you try to use buildman with the branch 'test' it will
complain that it is unsure whether you mean the branch or the directory.
This is a feature of the 'git log' command that buildman uses. Fix it
by resolving the ambiguity.
Signed-off-by: Simon Glass <[email protected]>
Reviewed-by: Joe Hershberger <[email protected]>
|
|
It is convenient to install symlinks to buildman and patman in the search
patch, such as /usr/local/bin. But when this is done, the -H option fails to
work because it looks in the directory containing the symlink instead of its
target. Fix this.
Signed-off-by: Simon Glass <[email protected]>
Reviewed-by: Joe Hershberger <[email protected]>
|
|
Fix this nit to keep the code consistent.
Signed-off-by: Simon Glass <[email protected]>
Reviewed-by: Joe Hershberger <[email protected]>
|
|
A patman series with a 'Series-notes' section causes
buildman to crash with:
self.series.notes += self.section
TypeError: cannot concatenate 'str' and 'list' objects
Fix by initializing series.notes as a one-element array
rather than a scalar.
Signed-off-by: Albert ARIBAUD <[email protected]>
Acked-by: Simon Glass <[email protected]>
Tested-by: Simon Glass <[email protected]>
|
|
Correct spelling of "U-Boot" shall be used in all written text
(documentation, comments in source files etc.).
Signed-off-by: Bin Meng <[email protected]>
Reviewed-by: Heiko Schocher <[email protected]>
Reviewed-by: Simon Glass <[email protected]>
Reviewed-by: Minkyu Kang <[email protected]>
|
|
Add option to create threaded series of patches.
With it, it will be possible to create patch threads like this:
[PATCH 0/10] Add support for time travel
[PATCH 1/10] Add Flux Capacitor driver
[PATCH 2/10] Add Mr. Fusion driver
(...)
Internally it will call git send-email with --thread option
Signed-off-by: Mateusz Kulikowski <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
This reverts commit 19b4a3369876f9215e2b861f211e8df1a75e26ca.
Since that commit, patman generates useless patches for file removal;
"git format -D" prints only the header but not the diff when deleting
files, and "git am" always refuses such patches.
The following is the quotation from "man git-format-patch":
-D, --irreversible-delete
Omit the preimage for deletes, i.e. print only the header but
not the diff between the preimage and /dev/null. The resulting
patch is not meant to be applied with patch nor git apply; this
is solely for people who want to just concentrate on reviewing
the text after the change. In addition, the output obviously
lack enough information to apply such a patch in reverse, even
manually, hence the name of the option.
Signed-off-by: Masahiro Yamada <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
This requires 'Series-cover_cc' at present which is incorrect. Fix it.
Signed-off-by: Simon Glass <[email protected]>
|
|
This allows Patman to generate smaller patches for file removal.
Signed-off-by: Masahiro Yamada <[email protected]>
Acked-by: Simon Glass <[email protected]>
Acked-by: Heiko Schocher <[email protected]>
|
|
Commit 488d19c (patman: add distutils based installer) has the side effect
of making patman run twice with each invocation. Fix this by checking for
'main program' invocation in patman.py. This is good practice in any case.
Signed-off-by: Simon Glass <[email protected]>
Reviewed-by: Chris Packham <[email protected]>
|
|
To make it easier to use patman on other projects add a distutils style
installer. Now patman can be installed with
cd u-boot/tools/patman && python setup.py install
There are also the usual distutils options for creating source/binary
distributions of patman.
Tested-by: Simon Glass <[email protected]>
Signed-off-by: Chris Packham <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
For the local project, we may specified format.subjectprefix setting.
Then the patch will be formated as [Project_prefix][PATCH].
But patman will not check this setting. It will remove the
format.subjectprefix.
So This patch will let patman check this setting and add it as a
project prefix.
Signed-off-by: Josh Wu <[email protected]>
Acked-by: Simon Glass <[email protected]>
Tested-by: Simon Glass <[email protected]>
|
|
Make cover letter shows like 0/x, 00/xx and 000/xxx etc.
Signed-off-by: Josh Wu <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
We should read this file to obtain a set of aliases. This reduces the need
to create them in the ~/.patman file.
This feature did exist in some version of patman, and is mentioned in the
help but it did not find its way upstream.
Reported-by: Graeme Russ <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
This causes an error when trying to build a local branch which has a local
branch as its upstream.
Signed-off-by: Simon Glass <[email protected]>
Reported-by: Masahiro Yamada <[email protected]>
|
|
Add an explanation for how to set up git so that patman can find the alias
file. Fix up the get_maintainers message too.
Reported-by: Scott Wood <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
True commit lines start at column zero. Anything that is indented
is part of the commit message instead. I noticed this by trying to
run buildman with commit e3a4facdfc07179ebe017a07b8de6224a935a9f3
as master, which contained a reference to a Linux commit inside
the commit message. ProcessLine saw that as a genuite commit
line, and thus buildman tried to build it, and died with an
exception because that SHA is not present in the U-Boot tree.
Signed-off-by: Scott Wood <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
When run with the --dry-run argument patman prints out information
showing what it would do. This information currently doesn't line up
with what patman/git send-email really do. Some basic examples:
- If an email address is addressed via "Series-cc" and "Patch-cc" patman
shows that email address would be CC-ed two times.
- If an email address is addressed via "Series-to" and "Patch-cc" patman
shows that email address would be sent TO and CC-ed.
- If an email address is addressed from a combination of tag aliases,
get_maintainer.pl output, "Series-cc", "Patch-cc", etc patman shows
that the email address would be CC-ed multiple times.
Patman currently does try to send duplicate emails like the --dry-run
output shows, but "git send-email" intelligently removes duplicate
addresses so this patch shouldn't change the non-dry-run functionality.
Change patman's output and email addressing to line up with the
"git send-email" logic. This trims down patman's dry-run output and
prevents confusion about what patman will do when emails are actually
sent.
Signed-off-by: Peter Tyser <[email protected]>
Acked-by: Simon Glass <[email protected]>
Tested-by: Simon Glass <[email protected]>
|
|
Adjust the -b flag to permit a range expression as well as a branch.
Signed-off-by: Simon Glass <[email protected]>
Suggested-by: Daniel Schwierzeck <[email protected]>
Tested-by: Daniel Schwierzeck <[email protected]>
|
|
Buildman normally obtains the upstream commit by asking git. Provided that
the branch was created with 'git checkout -b <branch> <some_upstream>' then
this normally works.
When there is no upstream, we can try to guess one, by looking up through
the commits until we find a branch. Add a function to try this and print
a warning if buildman ends up relying on it.
Also update the documentation to match.
Signed-off-by: Simon Glass <[email protected]>
Suggested-by: Wolfgang Denk <[email protected]>
|
|
Even with the initial 8 characeters of the hash we will sometimes get a
collision. Use the full hash.
Signed-off-by: Simon Glass <[email protected]>
|
|
The get_maintainers script is a useful default, but sometimes is copies
too many people, or takes a long time to run.
Add an option to disable it and update the README.
Signed-off-by: Simon Glass <[email protected]>
|
|
For an occasional user of patman some failures are not obvious: for
instance when checkpatch reports warnings, the dry run still reports
that the email would be sent. If it is not dry run, the warnings are
shown on the screen, but it is not clear that the email was not sent.
Add some code to report failure to send email explicitly.
Tested by running the script on a patch with style violations,
observed error messages in the script output.
Signed-off-by: Vadim Bendebury <[email protected]>
Reviewed-by: Doug Anderson <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
Tags like Series-version are normally expected to appear once, and with a
unique value. But buildman doesn't actually look at these tags. So ignore
conflicts.
This allows bulidman to build a branch containing multiple patman series.
Reported-by: Steve Rae <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
For reasons that are not well-understood, GetMetaDataForList() can end up
adding to an existing series even when it appears that it should be
starting a new one.
Change from using a default constructor parameter to an explicit one, to
work around this problem.
Signed-off-by: Simon Glass <[email protected]>
|
|
Add a test point for the command module. This allows tests to emulate
the execution of commands. This provides more control (since we can make
the fake 'commands' do whatever we like), makes it faster to write tests
since we don't need to set up as much environment, and speeds up test
execution.
Signed-off-by: Simon Glass <[email protected]>
|
|
RunPipe() currently pipes the output of stdout and stderr to a pty, but
this is not the intended behaviour. Fix it.
Signed-off-by: Simon Glass <[email protected]>
|
|
When running unit tests we don't want output to go to the terminal.
Provide a way of collecting it so that it can be examined by test code
later.
Signed-off-by: Simon Glass <[email protected]>
|
|
A missing 'global' declaration means that this feature does not currently
work. Fix it.
Signed-off-by: Simon Glass <[email protected]>
|
|
patman collects tags that it sees in the commit and places them nicely
sorted at the end of the patch. However, this is not really necessary and
in fact is apparently not desirable.
Suggested-by: Masahiro Yamada <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
Tested-by: Masahiro Yamada <[email protected]>
|
|
In a headless environment the pager can apparently hang. We don't want a
pager anyway so let's request that none be used.
Reported-by: Tom Rini <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
It seems that this is no longer needed, since checkpatch.pl will catch
whitespace problems in patches. Also the option is not widely used, so
it seems safe to just remove it.
Suggested-by: Masahiro Yamada <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
It seems that doctest behaves differently now, and some of the unit tests
do not run. Adjust the tests to work correctly.
./tools/patman/patman --test
<unittest.result.TestResult run=10 errors=0 failures=0>
Signed-off-by: Simon Glass <[email protected]>
|
|
This code came from a different project with 2-character indentation. Fix
it for U-Boot.
Signed-off-by: Simon Glass <[email protected]>
|
|
This option is currently not supported, but needs to be, for buildman to
operate as expected.
Reported-by: York Sun <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
"patman [options]" is displayed by default.
Append the rest of help messages to parser.usage
instead of replacing it.
Signed-off-by: Masahiro Yamada <[email protected]>
|
|
In Python, sys.exit() function can also take an object other
than an integer.
If an integer is given to the argument, Python exits with the return
code of it. If a non-integer argument is given, Python outputs it
to stderr and exits with the return code of 1.
That means,
print >> sys.stderr, "Blah Blah"
sys.exit(1)
is equivalent to
sys.exit("Blah Blah")
The latter is a useful shorthand.
Note:
Some error messages in Buildman and Patman were output to stdout.
But they should go to stderr. They are also fixed by this commit.
This is a nice side effect.
Signed-off-by: Masahiro Yamada <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
Older versions of git (e.g. Ubuntu 10.04) do not support this flag. By
default they do not decorate. So only enable this flag when supported.
Suggested-by: Tom Rini <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
Move the code that builds a 'git log' command into a function so we can more
easily adjust it.
Signed-off-by: Simon Glass <[email protected]>
|
|
If Series-to tag is missing, Patman exits with a message
"No recipient".
This is just annoying for those who had already added
sendemail.to configuration.
I guess many developers have
[sendemail]
to = [email protected]
in their .git/config because the 'To: [email protected]' field
should always be added when sending patches.
That seems more reasonable rather than adding
'Series-to: [email protected]' to every patch series.
Patman should exit only when both Series-to tag and sendemail.to
configuration are mising.
Signed-off-by: Masahiro Yamada <[email protected]>
Cc: Simon Glass <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
When patman applies the patches it checks out a new branch, uses 'git am'
to apply the patches one by one, and then tries to go back to the old
branch. If you try this when the branch is 'undefined', this doesn't work
as patman cannot restore the correct branch after applying the patches.
It seems that 'undefined' is created by git and is persistent after it is
created, so that you can end up on quite an old branch.
Add a check for the 'undefined' branch to avoid this.
Reported-by: Masahiro Yamada <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
|
|
There is an unfortunate bug in the signoff suppression logic. The first
pass is performed with 'git log', and all signoffs are added to the
supression set, such that the second time (when processing the real
patches) we always suppress the signoffs.
Correct this by only suppressing signoffs in the second pass.
Signed-off-by: Simon Glass <[email protected]>
Tested-by: Michal Simek <[email protected]>
Tested-by: Andreas Bießmann <[email protected]>
|
|
Keep track of all Signed-off-by tags in a commit and silently suppress any
duplicates.
Signed-off-by: Simon Glass <[email protected]>
|
|
This sort of failure is rare, but the code to deal with it is wrong.
Fix it.
Signed-off-by: Simon Glass <[email protected]>
|
|
Add a new Patch-cc: tag which performs the service now provided by
the Cc: tag. The Cc: tag is interpreted by git send-email but
ignored by patman.
So now:
Cc: patman does nothing. (git send-email can cc patches)
Patch-cc: patman Cc's patch and removes this tag from the patch
Signed-off-by: Simon Glass <[email protected]>
|
|
Sometimes a commit should have notes enclosed with it rather
than withing the cover letter -- possibly even because there
is no cover letter. Add a 'Commit-notes' tag, similar to the
'Series-notes' one; lines between this tag and the next END
line are inserted in the patch right after the '---' commit
delimiter.
Change-Id: I01e99ae125607dc6dec08f3be8a5a0b37f0a483d
Signed-off-by: Albert ARIBAUD <[email protected]>
Signed-off-by: Simon Glass <[email protected]>
(Updated README)
|
|
Signed-off-by: Wolfgang Denk <[email protected]>
[trini: Fixup common/cmd_io.c]
Signed-off-by: Tom Rini <[email protected]>
|
|
adjust instructions for the invocation of Patman's self test: the -t
flag appears to have a different meaning now, refer to the --test option
for the builtin unit test; adjust a directory location and make sure to
run the file which resides in the source directory
Signed-off-by: Gerhard Sittig <[email protected]>
Acked-by: Simon Glass <[email protected]>
|
|
Rather than a backtrace, produce a nice error message when an invalid
branch is provided to buildman.
Signed-off-by: Simon Glass <[email protected]>
|
|
Patman requires python 2.7.4 to run but it doesn't
need to be placed in /usr/bin/python.
Use env to ensure that the interpreter used is
the first one on environment's $PATH on system
with several versions of Python installed.
Signed-off-by: Michal Simek <[email protected]>
Reviewed-by: Tom Rini <[email protected]>
Acked-by: Simon Glass <[email protected]>
|