summaryrefslogtreecommitdiff
path: root/morphlib/app.py
Commit message (Collapse)AuthorAgeFilesLines
* Add write and configuration extensions to help.baserock/markdoffman/s10382/add-help-option-v2Mark Doffman2014-02-211-38/+51
| | | | | | | Add a command 'help-extensions' to list all extensions. Add the ability to find help on an extension by calling 'morph help [extension name]'. This will then call the extension with the '--help' option to obtain help text.
* Make '--help' and help subcommand the same.Mark Doffman2014-02-211-16/+53
| | | | | '--help' when used with a subcommand will show the subcommand help. Do not reflow the help text by using a custom formatter.
* Allow omitting repo and ref when referring to strataRichard Maw2014-02-131-5/+5
|
* Add --artifact-cache-server and --git-resolve-cache-serverLars Wirzenius2013-10-291-0/+14
|
* Merge branch 'danielfirth/RT193'Daniel Firth2013-10-111-1/+1
|\ | | | | | | | | Reviewed by: Lars Wirzenius Reviewed by: Pedro Alvarezwq
| * Added chunkname prefix to some elements of the debug log.Dan Firth2013-10-111-1/+1
| |
* | Morph now validates the 'tarball-server' option as a urlDaniel Firth2013-10-101-0/+14
|/
* Allow building with null repo/refRichard Maw2013-09-261-2/+6
|
* Avoid formatting "morph help foo" outputLars Wirzenius2013-09-241-0/+25
| | | | | | | | The cliapp formatting doesn't understand Markdown. Adding Markdown support in Morph is more work than there is time for right now, but we'll do it later. This quick hack just means we output the raw Markdown rather than something that is incomprehensible due to ruined formatting.
* Remove --staging-chroot, --staging-filler optionsLars Wirzenius2013-09-171-25/+0
| | | | | This also removes the long-obsolete code to install staging fillers in the staging area. We've not allowed users to do that for ages now.
* Set build-ref-prefix to be based on trove-id if the setting existsTiago Gomes2013-07-311-3/+9
|
* Don't show git config messages for 'morph branch' in verbose modeRichard Dale2013-06-251-3/+10
|
* Remove SystemKindBuilderFactoryLars Wirzenius2013-06-201-2/+0
| | | | | | We now only support one system-kind, so there's no need for the factory stuff, and at this point it only serves to obfuscate and complexify.
* Shorten create_if_not_exists logicRichard Maw2013-06-061-11/+7
| | | | | | | | I find the loop easier to read since there's less redundancy. Also less code to maintain. Note that tmpdir is not explicitly created, since makedirs of one of its subdirectories will handle that.
* process_args: Move directory creation to after dump configRichard Maw2013-06-061-4/+4
| | | | | | I put my directory creation logic there, since it's an unintended side-effect to create the directories if all you want to do is dump the config.
* Merge branch 'baserock/tiagogomes/tmpdir' of ↵Tiago Gomes2013-06-051-10/+18
|\ | | | | | | | | | | | | | | | | | | | | | | git://git.baserock.org/baserock/baserock/morph I had fixed an conflict and change to use morph_tmp instead of morph as default temp dir. Reviewed by Lars Wirzenius Conflicts: morphlib/app.py
| * Change the structure of the temporary directory used by morphTiago Gomes2013-06-051-5/+16
| | | | | | | | | | | | Now, inside the temporary directory we will have the following subdirectories: chunks, staging, failed and deployments. The failed directory will contain the staging areas of failed builds.
* | S7904: add new config options for minimum sizesRichard Maw2013-06-051-0/+28
| |
* | S7904: Move cache settings to storage optionsRichard Maw2013-06-051-10/+14
| |
* | Create cachedir and tempdir if they do not existRichard Maw2013-06-051-0/+6
|/ | | | | | | | | | | This has been a thorn in my side for many a deployment. A nascent cache directory will cause the size checks to fail. We could get complicated and try the parent directories, or create the directories in the size check, but the former is not worth the complication and the latter is the wrong place to put it, so do it during process_args, so the directories exist before subcommands are run, so they don't have to bother with it themselves.
* Merge branch 'liw/kill-bare-except'Lars Wirzenius2013-05-281-2/+2
|\ | | | | | | | | | | | | Reviewed-by: Richard Maw I, Lars, note that we have an old version of CoverageTestRunner in Baserock. The new version hides the spurious logging messages.
| * Stop using bare except: statementsLars Wirzenius2013-04-161-2/+2
| | | | | | | | | | | | | | | | | | It is almost never a good idea to catch all exceptions, and then do nothing about them. This patch logs all caught exceptions so that the user has some possibilty to debug what is happening. Also, make ./check check for bare excepts and fail the test suite if it finds anything.
* | Remove executable permissions from *.py files that have themLars Wirzenius2013-05-281-0/+0
| |
* | Merge branch 'ps/to-trove-id'Lars Wirzenius2013-05-271-3/+3
|\ \ | |/ |/| | | Changed Paul's patch so that --trove-prefix still works as an alias.
| * rename trove-prefix and trove_prefix to trove_idPaul Sherwood2013-04-131-3/+3
|/
* Fix condition for showing the staging-filler warningLars Wirzenius2013-03-201-1/+1
| | | | | | | If there is no staging-filler setting in a configuration file, it defaults to the empty string, not None. Reviewed-by: Jonathan Maw over the shoulder
* Warn if staging fillers are usedSam Thursfield2013-03-201-1/+5
| | | | | The 'master' branch of baserock:baserock/morphs no longer requires a staging filler.
* Add 'prefix' property for chunks within strataSam Thursfield2013-03-131-5/+0
| | | | | | | | | Morph no longer supports setting the prefix using the --prefix argument / setting. This was only used in tests and during bootstrap. If a chunk build-depends on a chunk within a stratum which has a custom prefix, that prefix is appended to the PATH in the build environment.
* Set environment variables defining target for build-essentialSam Thursfield2013-03-131-18/+0
| | | | | | In the future we will allow this to be modified to provide a cross-bootstrap mode, but for now we use the same target as the host compiler.
* Remove features used by old bootstrap methodSam Thursfield2013-03-131-24/+32
| | | | | | That means that bootstrapping Baserock is currently not possible with this branch of Morph, but there's no reason it cannot be bootstrapped using an older version of Morph instead.
* Change morph to reduce loogign of the environmentRic Holland2013-03-081-2/+3
| | | | | | | | Added function log_dict_diff to identify and record changes in dicts to the debug log This new function was then implemented in app.py to log changes in the environment
* Fix settings['tempdir'] not being setJonathan Maw2013-03-011-0/+5
|
* Make BuildCommand report current and total build stepsLars Wirzenius2013-02-211-1/+7
| | | | | | This adds a [Build 1/12765] to the output of the building of each artifact. This makes it easier to see how much work there might still be remaining.
* Remove deprecated functionsSam Thursfield2013-02-061-24/+0
|
* Fix copyright yearSam Thursfield2013-01-291-1/+1
|
* Disable distcc by defaultSam Thursfield2013-01-291-2/+3
| | | | | | | | | | | | | | | Current versions of build-essential in the Baserock morphologies don't contain distcc, but Morph tries to use distcc anyway. Since useful operation of distcc requires setting up a distcc network, there's no reason for it to be on by default. This change fixes bootstrap, and means that users of the build-essential staging filler no longer have to set no-distcc=true manually. In the future, cliapp will grow automatic boolean negation, which will allow us to turn this setting into a 'distcc' setting that defaults to false rather than the current rather ugly double negative.
* Fix default setting for compiler cache dir; update testsJannis Pohlmann2012-12-171-4/+7
| | | | Reviewed-by: Lars Wirzenius <lars.wirzenius@codethink.co.uk>
* Add support for ccacheJonathan Maw2012-12-171-14/+5
| | | | | | | | | | | | | | | | | | | This is set up so that each individual project repository has its own ccache, all under one defined directory. The top-level ccache directory is added as the setting 'compiler-cache-dir', and defaults to $cachedir/ccache. When a build is performed, this will bind-mount a project's ccache into the /tmp/ccache of the staging-area and set up the environment variables so that ccache will be used (if appropriate executables are installed to /usr/lib/ccache in the staging-area). In addition, this removes code for ccache-remotedir, as it is unrelated to this implementation of ccache. Reviewed-by: Jannis Pohlmann <jannis.pohlmann@codethink.co.uk> Reviewed-by: Lars Wirzenius <lars.wirzenius@codethink.co.uk>
* Cache resolved refs and morphologies when traversing morphsJannis Pohlmann2012-12-131-4/+18
| | | | | | | This cuts down on the number of HTTP requests made while computing th build order (> create source pool > traverse morphs). In an example system I was building this patch reduced the requests from 501 to 195, reducing the time to building the first chunk from 123s to 18s.
* morph build: Allow forcing build branches to be pushedSam Thursfield2012-11-121-0/+4
| | | | | This is for users who prefer the old behaviour of building from the remote repos.
* Set option group for some advanced settingsSam Thursfield2012-10-311-20/+36
| | | | | | | | It would be nice to put every option in a group, but for now the built-in cliapp options cannot be grouped so the output is less than ideal. Also, we have no way of setting an order for groups, which results in e.g. 'Advanced Options' preceeding 'General Options' etc.
* Reduce some option descriptionsSam Thursfield2012-10-261-27/+13
|
* Reorder settings by broad categorySam Thursfield2012-10-261-58/+59
| | | | | | | | Also remove the '--ignore-submodules' option, which is redundant. Hopefully cliapp will one day support option grouping, so we can hide some sets by default and group eg. all the logging options together.
* Change the time sanity checkLars Wirzenius2012-10-081-13/+6
| | | | | | | | | | | | | We were having trouble with NTP setting the system time to be correct after .pyc files had already been created. The .pyc files got created at startup, before NTP had had a chance to run. This sometimes resulted in .pyc timestamps being wildly wrong and far in the future or past, and that would prevent morph from ever working again on the machine. We now just check that the system time is not far in the past. This is enough to make sure we don't create timestamps that break tar. Reviewed-By: Daniel Silverstone (on irc)
* No need for iterable when initializing the setJames Thomas2012-10-011-1/+1
|
* Only update repos onceJames Thomas2012-10-011-1/+5
|
* Increase verbosity regarding the remote artifact cache.Daniel Silverstone2012-09-281-1/+8
| | | | | | | This simply increases the verbosity of the operations which are done against the remote artifact cache. It should result in some progress messages if you build with --verbose set and you're mostly getting stuff from your remote artifact cache (Trove).
* Use tarballs instead of bundlesDaniel Silverstone2012-09-251-5/+5
| | | | | | | This makes a non-backward-compatible change to morph which switches it to using tarballs instead of bundles when initialising cached git repositories. This is faster because it doesn't require index-pack --fix-thin operations on the machine running morph.
* Default bundle-server and cache-server based on trove-host.Daniel Silverstone2012-09-251-3/+13
| | | | | | | This causes bundle-server and cache-server to be defaulted to appropriate Trove related URLs unless overridden in the configs. Reviewed-By: Lars Wirzenius <lars.wirzenius@codethink.co.uk>
* Merge branch 'baserock/radiofree/check_mtime'Lars Wirzenius2012-09-241-0/+15
|\