summaryrefslogtreecommitdiff
path: root/bin
AgeCommit message (Collapse)Author
2025-02-20just-lock: Add utility doing own parsing before fetching archivePaul Cristian Sarbu
Preparatory commit for implementation of '--clone' option.
2025-02-20just-lock: Add option to set a just binary to usePaul Cristian Sarbu
2025-02-20just-lock: Support special pragma for plain importsPaul Cristian Sarbu
Marking a source repository 'as plain' means that the whole source repository tree will get imported as a repository type corresponding to the source type. In this case, additional pragmas than those supported by the inndividual imports might need to be set. Solve this by supporting the just-mr-style 'pragma' field also in the source description, for all sources also accepting the 'as plain' field. Currently support only the 'special' pragma. Document change and add test for plain imports that checks this feature.
2025-02-20just-lock: Improve handling of pragmas in 'repos' import descriptionPaul Cristian Sarbu
In particular, any transitive 'file'-type repository will inherit any given '{to_git: true}' pragma in the import description objects. Note that this technically can only happen for transitive 'file' repositories imported from a 'file' source, so in all other cases such a pragma would not have any effect. Document change and extend the import from 'file' source test to check this feature.
2025-02-20just-import-git: Fix missing inherited pragmasPaul Cristian Sarbu
Update CHANGELOG accordingly.
2025-02-20just-lock: Fix missing inherited pragmasPaul Cristian Sarbu
Transitive 'file'-type repositories should inherit any pragmas suported by the new repository type they are rewritten as. Extend import tests to avoid regressing on this issue in the future.
2025-01-29just-lock: Search for archives to fetch also in Git cachePaul Cristian Sarbu
...before trying remotes.
2025-01-29just-lock: Run commit check command only on existing repositoriesPaul Cristian Sarbu
While there, improve docstrings of methods operating on Git repositories to specify when the underlying Git repositories are expected to be present.
2025-01-29just-lock: Add support for 'tree structure' rootsPaul Cristian Sarbu
Based on f0473730 and 22ef0a16
2025-01-29just-lock: Fix deduplication of 'computed' rootsPaul Cristian Sarbu
Based on 76ce2123
2025-01-29just-lock: Normalize subdir before checking if non-upwardPaul Cristian Sarbu
2025-01-29just-lock: Improve error handling for importing to GitPaul Cristian Sarbu
2025-01-29just-lock: Ensure all commands use the run_cmd methodPaul Cristian Sarbu
2025-01-29just-deduplicate-repos: Fix formattingPaul Cristian Sarbu
2025-01-29just-lock config: Make field names consistent with just-mrPaul Cristian Sarbu
2025-01-21Exclude 'tree_structure' directory from bootstrappingMaksim Denisov
2025-01-20just-lock: Implement import source 'git-tree'Paul Cristian Sarbu
2025-01-17just-lock: Move import utilities code sectionPaul Cristian Sarbu
...below the GitCAS and CAS utilities, in order for those to be available for use when implementing the other import source types.
2025-01-17just-lock: Improve handling of 'subdir' pathsPaul Cristian Sarbu
Enforce 'subdir' field of 'archive' import source to also be non-upward. Normalize subdirs during rewrite of dependent 'file'-type repositories.
2025-01-17just-import-git: Normalize 'subdir' path during repository rewritePaul Cristian Sarbu
2025-01-16just-lock: Do not use temp dirs outside local build rootPaul Cristian Sarbu
2025-01-13import tools: Fix rewrite of unneeded fieldsPaul Cristian Sarbu
The rewrite logic assumes that for repositories taken as layers we will not have certain fields and so they are unconditionally reassigned. Fix this by extending the existing check for bindings to include also alternative roots and root files.
2025-01-10just-lock: Implement 'archive' import sourcePaul Cristian Sarbu
Use local CAS to cache fetched archives. Take the storage garbage collector shared lock to guard against unwanted generation rotations.
2025-01-10just-lock: Use the GitCAS during 'git' source importsPaul Cristian Sarbu
Add file locking logic; guard critical Git operations with the same approach as in Just and also take the repositories garbage collector shared lock to guard against unwanted generation rotations.
2025-01-10just-lock: Try also mirrors when importing known commit from Git reposPaul Cristian Sarbu
When commit to fetch is known, check mirrors before going to the main URL. While there, ensure the context for logging in the checkout method is not replaced, but appended to.
2025-01-10just-lock: Add attempts argument to method running commandsPaul Cristian Sarbu
2025-01-10just-lock: Improve docstrings and method signaturesPaul Cristian Sarbu
...to better reflect intent. In particular, improve the name of the variable storing the partial description to be used during rewrite of dependent 'file'-type repositories brought in by an import.
2025-01-10just-lock: Improve directory tree removalPaul Cristian Sarbu
2025-01-10just-lock: Fix 'repositories' field not updated in import loopPaul Cristian Sarbu
2025-01-09Support deduplication of "tree structure" rootsMaksim Denisov
2025-01-09Support import of "tree structure" rootsMaksim Denisov
2025-01-08Fix deduplication of target repos in precomputed rootsMaksim Denisov
2024-12-17just-lock: Implement import source type 'file'Paul Cristian Sarbu
2024-12-17just-lock: Improve error handling of command line parsingPaul Cristian Sarbu
2024-12-17just-lock: Match logging style of just-mr, including colorsPaul Cristian Sarbu
Use the RGB values of the predefined fmt library colors that both just and just-mr use.
2024-12-17just-lock: Fix plain configuration map for 'git' importsPaul Cristian Sarbu
While there, also improve check for early return from import method.
2024-12-11Initial implementation of just-lockPaul Cristian Sarbu
Able to handle imports from Git repositories and deduplicate the resulting configuration.
2024-12-10just-deduplicate-repos: Add support for computed repositoriesPaul Cristian Sarbu
2024-12-10just-import-git: Add support for computed repositoriesPaul Cristian Sarbu
2024-11-29just-import-git: Fix foreign config locationPaul Cristian Sarbu
As per documentation, if a location is given for the configuration file in the foreign repository then it must be taken relative to its root. However, in our implementation this location is taken relative to the current directory. Fix this.
2024-11-28bin scripts: Use the NoReturn type hintPaul Cristian Sarbu
The NoReturn type hint should be used to ensure the return type of methods calling no-return methods are not falsely enforced to an Optional return type. Add the NoReturn type hint as needed and clear up existing Optional returns together with any corresponding casts affected by the above. While there, also fix formatting.
2024-11-21Materialize computed roots before top-level analysisKlaus Aehlig
Add a basic implementation of computed roots. So far we neither enforce nor make good use of the fact that the underlying target of a computed root has to be an export target of a content-fixed repository; instead, we always install the root to a temporary directory and pick it up from there. Still, the basic functionality is there, and it is minimally useful.
2024-11-06Make bootstrap-traverser aware of the "cwd" property of actionsKlaus Aehlig
2024-10-10bootstrap traversing: for explicit trees, create closed directoriesKlaus Aehlig
... by recursively copying and resolving sybolic links. In this way, references within a tree (e.g., #include "../Something.hpp") do not confuse the compiler, as opposed to directory symlinks. Neverthess, by doing this copying only for tree constructors, we still keep the overhead acceptable.
2024-08-26just-mr.py: Accept all tree entries for bootstrapped justPaul Cristian Sarbu
The Python script used for the first stage of bootstrapping just uses the Git index to create trees from directories (be it file repositories, unpacked archives, or distfiles), therefore it has the limitations of Git itself in committing trees that contain entries ignored by Git, such as empty directories, the .git folder, .gitignore files and files referenced there, or other entries with Git-specific magic names. This commit updates the Python script to replace the use of the Git index for importing directories to directly writing the needed blobs and trees to the object database, then commit the resulting top tree explicitly. While there, fix a typing issue from our relaxed approach in using os.environ to set the subprocess env when running commands. As on POSIX the type is _Environ, not simple Dict[str, str], use implicit dictionary merging (Python v3.5+) to set the Git envars. The issue was initially flagged by pyright.
2024-07-19Storage config: change layout to support several storage generationsKlaus Aehlig
2024-06-18Use ServeApi during bootstrapMaksim Denisov
...with a default implementation. Although it is not used directly, it will be needed for instantiation of std::optional.
2024-04-25just-deduplicate-repos: merge pragma of identified repositoriesKlaus Aehlig
While just-deduplcate-repos only identifies repositories that are semantically indistinguishable, there still is the pragma to consider. - If the repository in one use requires to be present, we have to fetch it, hence cannot treat it as absent. - If a repository in one place has to be transformed to a git root, this also has to happen for the copy we keep.
2024-04-25just-import-git: support importing repositories as absentKlaus Aehlig
This allows to simply specify the direct dependencies desired to be absent at import where the dependency structure is handled anyway, rather than afterwards reconstructing which repositories should be absent.
2024-02-21just-import-git: support setting "inherit env"Klaus Aehlig
When importing a repository via just-import-git, allow to specify the value for the "inherit env" property for the repository just being imported.