summaryrefslogtreecommitdiff
path: root/src/ostree/ot-builtin-export.c
Commit message (Collapse)AuthorAgeFilesLines
* tree-wide: Run clang-formatColin Walters2023-05-021-27/+31
| | | | | This is a one-time tree wide reformatting to ensure consistency going forward.
* Strip trailing whitespace on all C filesDan Nicholson2023-02-071-3/+3
| | | | | | | | My editor started following the configuration in .editorconfig and is applying this rule to many files I'm editing. Let's just get this over with and strip everything. This was done like so: git ls-files | grep '\.[ch]$' | xargs sed -ri 's/\s+$//'
* Update FSF license notices to use URL instead of addressJoseph Marrero2021-12-071-3/+1
|
* Add SPDX-License-Identifier to source filesMarcus Folkesson2018-01-301-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | SPDX License List is a list of (common) open source licenses that can be referred to by a “short identifier”. It has several advantages compared to the common "license header texts" usually found in source files. Some of the advantages: * It is precise; there is no ambiguity due to variations in license header text * It is language neutral * It is easy to machine process * It is concise * It is simple and can be used without much cost in interpreted environments like java Script, etc. * An SPDX license identifier is immutable. * It provides simple guidance for developers who want to make sure the license for their code is respected See http://spdx.org for further reading. Signed-off-by: Marcus Folkesson <marcus.folkesson@gmail.com> Closes: #1439 Approved by: cgwalters
* ostree: provide command description in a better placeRuixin Bao2017-10-201-1/+1
| | | | | | | | | | | | | | | | | | | This is similar idea as https://github.com/projectatomic/rpm-ostree/pull/916/commits/5c0bf889155573feec108501ce849ac09a0c9567, The duplicated description is now removed, and the description of the command is now displayed beneath the Usage. For example: ostree cat -h will output the following: "Usage: ostree cat [OPTION?] COMMIT PATH... Concatenate contents of files" Closes: #1267 Approved by: cgwalters
* ostree: move flags into command struct, pass down through builtinsRuixin Bao2017-10-201-2/+2
| | | | | | | | | | | | | | | | | | | | This is a similar approach as https://github.com/projectatomic/rpm-ostree/commit/12c34bb2491a07079c911ef26401fee939e5573c. One thing to note is when we parse the admin related functions, we still keep the old admin related flags, and added a new parameter to represent the command struct. This allows us to identify the caller of the function, making it easier for us to possibly deduplicate the subcommand handling in the future. A similar approach is done in rpm-ostree: https://github.com/projectatomic/rpm-ostree/commit/83aeb018c1012c7a43783c09b74ec71bc9c45826 This also makes it easier for us to change the prototype of the function. If we want to add something new in the future, we won't need to touch every prototype. Closes: #1267 Approved by: cgwalters
* tree-wide: Remove Emacs modelinesColin Walters2017-09-211-2/+1
| | | | | | | | | We added a `.dir-locals.el` in commit: 9a77017d87b74c5e2895cdd64ad098018929403f There's no need to have it per-file, with that people might think to add other editors, which is the wrong direction. Closes: #1206 Approved by: jlebon
* tree-wide: Squash a few warnings when building with no featuresColin Walters2017-09-211-2/+2
| | | | | | | | Noticed these since I had a local configured build with no features for testing the PAPR context for it. Closes: #1201 Approved by: jlebon
* ostree: Add naggy comments to help keep options in syncMatthew Barnes2017-08-151-0/+5
| | | | | | | | | | /* ATTENTION: * Please remember to update the bash-completion script (bash/ostree) and * man page (man/ostree-$COMMANDNAME.xml) when changing the option list. */ Closes: #1080 Approved by: cgwalters
* tree-wide: Fix the build with old glib (Ubuntu Trusty etc.)Colin Walters2017-08-031-2/+4
| | | | | | | | This regressed with <https://github.com/ostreedev/ostree/pull/1040> but currently the Travis builds aren't gating. Closes: #1051 Approved by: jlebon
* tree-wide: Use g_autoptr(Ostree*)Colin Walters2017-08-031-1/+1
| | | | | | | | | | | Part of cleaning up our usage of libglnx; we want to use what's in GLib where we can. Had to change a few .c files to `#include ostree.h` early on to pick up autoptrs for the core types. Closes: #1040 Approved by: jlebon
* tree-wide: Use GLib autocleanups for libarchiveColin Walters2017-08-021-1/+1
| | | | | | | | | Define typedefs for read/write archives, and use the GLib autocleanups for them. Prep for updating libglnx to drop its custom autocleanup macros. Closes: #1042 Approved by: jlebon
* ostree: Use G_OPTION_ARG_FILENAME where appropriatePhilip Withnall2017-04-271-3/+3
| | | | | | | | | | | | | Instead of using G_OPTION_ARG_STRING, use G_OPTION_ARG_FILENAME, which handles filename encoding conversion differently from the locale conversion which G_OPTION_ARG_STRING. This will fix argument handling on systems where the filename encoding is not the same as the locale encoding (which is fairly unlikely since most systems use UTF-8). Signed-off-by: Philip Withnall <withnall@endlessm.com> Closes: #810 Approved by: cgwalters
* tree-wide: Switch to autoptr for GOptionContextColin Walters2016-12-081-3/+1
| | | | | | | | | | We were leaking in a few places that I noticed in an ASAN run. Also, this was one of the last non-autoptr cleanup sections we have in `out:` cleanup sections, making us a lot closer to a potential full-tree rewrite to `return FALSE`. Closes: #624 Approved by: jlebon
* Define and use cleanup helpers for libarchiveColin Walters2016-12-051-5/+2
| | | | | | | | This should fix some of the ASAN leaks around libarchive usage, and is generally better. Closes: #609 Approved by: jlebon
* [ASAN] lib: Squash various leaks in library and commandlineColin Walters2016-11-211-1/+5
| | | | | | | | The pull one is the most likely to affect users. Otherwise mostly just cleaning up `-fsanitize=address`. Closes: #587 Approved by: jlebon
* ostree export: Add --prefix optionAlexander Larsson2016-04-191-0/+4
| | | | | | | | | This lets you set a prefix for the resulting archive patsh. Especially useful in combination with --subpath, for instance --subpath=subdir --prefix=subdir to extract just subdir. Closes: #265 Approved by: cgwalters
* ostree export: Add --subpath supportAlexander Larsson2016-04-191-1/+9
| | | | | | | This lets you export a subset of a commit. Closes: #265 Approved by: cgwalters
* Rename libarchive write API to "export", matching command lineColin Walters2016-02-191-3/+3
| | | | | | | | | | I was going to add new API for importing, and it was really confusing that what I think of now as import and export both had "write" in the name. It's just clearer to talk about the direction. At the same time, include `Export` in the options structure. This isn't an ABI break as the API isn't in a release.
* Add an `export` builtin, and API to write to libarchiveColin Walters2016-02-141-0/+148
At the moment I'm looking at using rpm-ostree to manage RPM inputs which can then be converted into Docker images. It's most convenient if we can stream directly out of libostree rather than doing a checkout + tar combination. There are also backup/debugging etc. reasons to implement `export` as well.