Skip to content

Commit

Permalink
Merge branch 'gix-archive'
Browse files Browse the repository at this point in the history
  • Loading branch information
Byron committed Jul 22, 2023
2 parents 9064ea3 + 44d9df4 commit 1dda48b
Show file tree
Hide file tree
Showing 47 changed files with 2,542 additions and 85 deletions.
126 changes: 126 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 8 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -118,24 +118,27 @@ pretty-cli = [ "gitoxide-core/serde", "prodash/progress-tree", "prodash/progress
prodash-render-line-crossterm = ["prodash-render-line", "prodash/render-line-crossterm", "prodash/signal-hook", "is-terminal", "crosstermion"]

## Progress reporting with a TUI, can then be enabled with the `--progress` flag.
prodash-render-tui = ["prodash/render-tui", "prodash/render-tui-crossterm", "prodash/progress-tree", "futures-lite"]
prodash-render-tui = ["prodash/render-tui", "prodash/render-tui-crossterm", "gix/progress-tree", "futures-lite"]

## Progress reporting by visually drawing lines into the terminal without switching to an alternate window.
prodash-render-line = ["prodash/render-line", "prodash-render-line-crossterm", "prodash/progress-tree"]
prodash-render-line = ["prodash/render-line", "prodash-render-line-crossterm", "gix/progress-tree"]

## Prints statistical information to inform about cache efficiency when those are dropped.
## Use this as a way to understand if bigger caches actually produce greater yiedls.
cache-efficiency-debug = ["gix-features/cache-efficiency-debug"]

## A way to enable most `gitoxide-core` tools found in `ein tools`, namely `organize` and `estimate hours`.
gitoxide-core-tools = ["gitoxide-core/organize", "gitoxide-core/estimate-hours"]
gitoxide-core-tools = ["gitoxide-core/organize", "gitoxide-core/estimate-hours", "gitoxide-core-tools-archive"]

## A program to perform analytics on a `git` repository, using an auto-maintained sqlite database
gitoxide-core-tools-query = ["gitoxide-core/query"]

## A program to run algorithms on a corpus of repositories, recording each run for later comparison.
gitoxide-core-tools-corpus = ["gitoxide-core/corpus"]

## A sub-command to generate archive from virtual worktree checkouts.
gitoxide-core-tools-archive = ["gitoxide-core/archive"]

#! ### Building Blocks for mutually exclusive networking
#! Blocking and async features are mutually exclusive and cause a compile-time error. This also means that `cargo … --all-features` will fail.
#! Within each section, features can be combined.
Expand Down Expand Up @@ -199,7 +202,7 @@ overflow-checks = false
# this bloats files but assures destructors are called, important for tempfiles. One day I hope we
# can wire up the 'abrt' signal handler so tempfiles will be removed in case of panics.
panic = 'unwind'
codegen-units = 1
#codegen-units = 1
incremental = false
build-override = { opt-level = 0 }

Expand Down Expand Up @@ -265,6 +268,7 @@ members = [
"gix-tui",
"gix-tix",
"gix-archive",
"gix-worktree-stream",
"gix-revwalk",

"cargo-smart-release",
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ is usable to some extent.
* [gix-worktree](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-worktree)
* [gix-bitmap](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-bitmap)
* [gix-negotiate](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-negotiate)
* [gix-worktree-stream](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-worktree-stream)
* `gitoxide-core`
* **very early** _(possibly without any documentation and many rough edges)_
* [gix-date](https://github.com/Byron/gitoxide/blob/main/crate-status.md#gix-date)
Expand Down
27 changes: 19 additions & 8 deletions crate-status.md
Original file line number Diff line number Diff line change
Expand Up @@ -600,7 +600,7 @@ See its [README.md](https://github.com/Byron/gitoxide/blob/main/gix-lock/README.

### gix
* [x] utilities for applications to make long running operations interruptible gracefully and to support timeouts in servers.
* [ ] handle `core.repositoryFormatVersion` and extensions
* [x] handle `core.repositoryFormatVersion` and extensions
* [x] support for unicode-precomposition of command-line arguments (needs explicit use in parent application)
* **Repository**
* [x] discovery
Expand Down Expand Up @@ -692,15 +692,16 @@ See its [README.md](https://github.com/Byron/gitoxide/blob/main/gix-lock/README.
* [ ] checkout with conversions like clean + smudge as in `.gitattributes`
* [ ] _diff_ index with working tree
* [ ] sparse checkout support
* [ ] read per-worktree config if `extensions.worktreeConfig` is enabled.
* [x] read per-worktree config if `extensions.worktreeConfig` is enabled.
* **index**
* [ ] tree from index
* [ ] index from tree
* [x] index from tree
* **worktrees**
* [x] open a repository with worktrees
* [x] read locked state
* [ ] obtain 'prunable' information
* [x] proper handling of worktree related refs
* [x] create a byte stream and create archives for such a stream, including worktree filters and conversions
* [ ] create, move, remove, and repair
* [x] access exclude information
* [x] access attribute information
Expand All @@ -724,13 +725,23 @@ See its [README.md](https://github.com/Byron/gitoxide/blob/main/gix-lock/README.
* [ ] API documentation
* [ ] Some examples

### gix-worktree-stream

* [x] encode git-tree as stream of bytes (with large file support and actual streaming)
* [x] produce a stream of entries
* [x] add custom entries to the stream
* [x] respect `export-ignore` git attribute
* [x] apply standard worktree conversion to simulate an actual checkout
* [ ] support for submodule inclusion
* [x] API documentation
* [ ] Some examples

### gix-archive

* [ ] `write_to()` for creating an archive with various container formats
* [ ] add custom entries to the archive
* [ ] handling of archive specific filters
* [ ] filter files of tree (with access to attributes)
* [ ] support for worktree conversion (via attributes and filters)
* [x] `write_to()` for creating an archive with various container formats
* [x] `tar` and `tar.gz`
* [x] `zip`
* [x] add prefix and modification date
* [ ] API documentation
* [ ] Some examples

Expand Down
3 changes: 2 additions & 1 deletion deny.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ allow = [
"MIT-0",
"ISC",
"Unicode-DFS-2016",
"LicenseRef-ring"
"LicenseRef-ring",
"Zlib"
]
# Lint level for licenses considered copyleft
copyleft = "allow"
Expand Down
1 change: 1 addition & 0 deletions etc/check-package-size.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ echo "in root: gitoxide CLI"
(enter cargo-smart-release && indent cargo diet -n --package-size-limit 110KB)
(enter gix-actor && indent cargo diet -n --package-size-limit 5KB)
(enter gix-archive && indent cargo diet -n --package-size-limit 10KB)
(enter gix-worktree-stream && indent cargo diet -n --package-size-limit 40KB)
(enter gix-utils && indent cargo diet -n --package-size-limit 10KB)
(enter gix-fs && indent cargo diet -n --package-size-limit 10KB)
(enter gix-pathspec && indent cargo diet -n --package-size-limit 30KB)
Expand Down
4 changes: 4 additions & 0 deletions gitoxide-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ query = ["dep:rusqlite"]
## *Note that* `organize` we need for finding git repositories fast.
corpus = [ "dep:rusqlite", "dep:sysinfo", "organize", "dep:crossbeam-channel", "dep:serde_json", "dep:tracing-forest", "dep:tracing-subscriber", "dep:tracing", "dep:parking_lot" ]

## The ability to create archives from virtual worktrees, similar to `git archive`.
archive = ["dep:gix-archive-for-configuration-only", "gix/worktree-archive"]

#! ### Mutually Exclusive Networking
#! If both are set, _blocking-client_ will take precedence, allowing `--all-features` to be used.

Expand All @@ -44,6 +47,7 @@ serde = ["gix/serde", "dep:serde_json", "dep:serde", "bytesize/serde"]
gix = { version = "^0.49.1", path = "../gix", default-features = false }
gix-pack-for-configuration-only = { package = "gix-pack", version = "^0.40.0", path = "../gix-pack", default-features = false, features = ["pack-cache-lru-dynamic", "pack-cache-lru-static"] }
gix-transport-configuration-only = { package = "gix-transport", version = "^0.34.0", path = "../gix-transport", default-features = false }
gix-archive-for-configuration-only = { package = "gix-archive", version = "^0.2.0", path = "../gix-archive", optional = true, features = ["tar", "tar_gz"] }
serde = { version = "1.0.114", optional = true, default-features = false, features = ["derive"] }
anyhow = "1.0.42"
thiserror = "1.0.34"
Expand Down
Loading

0 comments on commit 1dda48b

Please sign in to comment.