Files
orx/orx-jvm/orx-git-archiver/README.md
2023-04-05 08:09:10 +00:00

27 lines
701 B
Markdown

# orx-git-archiver
An extension that hooks into `Program.requestAssets` to commit
changed code to Git and provide filenames based on the commit hash.
## How do I use it?
```kotlin
application {
program {
extend(GitArchiver()) {
}
extend(Screenshots())
}
}
```
Now when a screenshot is taken, first all uncommitted code is committed to git.
The screenshot is saved with the first 7 characters of the commit hash in the filename.
<!-- __demos__ -->
## Demos
### GitArchiverDemo01
[source code](src/demo/kotlin/GitArchiverDemo01.kt)
![GitArchiverDemo01Kt](https://raw.githubusercontent.com/openrndr/orx/media/orx-jvm/orx-git-archiver/images/GitArchiverDemo01Kt.png)