Commit Graph

25 Commits

Author SHA1 Message Date
Benjamin Renard a27af14040 Switch from Woodpecker CI to Forgejo Actions
Run tests / test-precommit (push) Successful in 1m5s Details
2024-03-10 19:40:53 +01:00
Benjamin Renard a5a91d14cf Allow to use this repository as Forgejo Action
ci/woodpecker/push/woodpecker Pipeline was successful Details
2024-03-10 18:12:54 +01:00
Benjamin Renard 0b15f1c2a8 CI: use pre-commit to run all tests
ci/woodpecker/push/woodpecker Pipeline was successful Details
2024-01-22 00:36:39 +01:00
Benjamin Renard 4d4a3839fa Introduce pre-commit hooks and code cleaning 2024-01-22 00:34:17 +01:00
Benjamin Renard 305af47086 docs.md: Fix author vs authors key 2024-01-22 00:12:18 +01:00
Benjamin Renard 5aa1664636
Add force_overwrite parameter 2023-07-19 19:26:50 +02:00
Benjamin Renard e7b4cfda7a Add doc file designed to be used to reference the plugin on the Woodpecker CI website
ci/woodpecker/push/woodpecker Pipeline was successful Details
2023-01-03 01:14:13 +01:00
Benjamin Renard 7837978fd1 revert 4d26837acc
ci/woodpecker/push/woodpecker Pipeline was successful Details
revert Mise à jour de 'docs.md'
2023-01-03 00:53:30 +01:00
Benjamin Renard 4d26837acc Mise à jour de 'docs.md'
ci/woodpecker/push/woodpecker Pipeline was successful Details
2023-01-03 00:52:50 +01:00
Benjamin Renard 6d9f984503 CI: fix tests
ci/woodpecker/push/woodpecker Pipeline was successful Details
2022-12-16 12:53:38 +01:00
Benjamin Renard 247030216c pylint: ignore invalid-name warnings
ci/woodpecker/push/woodpecker Pipeline failed Details
2022-12-14 12:53:54 +01:00
Benjamin Renard 65a6445ce7 Use underscore instead of dash to compute repository/snapshot name
Dash are commonly used in distribution, prefix and component name.
Prefer using underscore to easily split distribution/prefix/component
from names.
2022-12-14 12:49:04 +01:00
Benjamin Renard 8b8c5032b1 Update the README.md file
ci/woodpecker/push/woodpecker Pipeline failed Details
2022-12-13 21:20:16 +01:00
Benjamin Renard 51511e9746 Remove unsed DISTRIBUTIONS variable 2022-12-13 21:19:57 +01:00
Benjamin Renard ce4d6a65e3 Improvments to correctly handle prefix, component name & distribution to compute repository and snapshot name
The repository name could now be computed from prefix, distribution and
component names. Format:
  {prefix}-{distribution}-{component}

Note: if the default prefix is specified ("."), it will not be used to
compute the repository name.

So, all works is now done by itering on detected changes files. Foreach
of then:
 - the changes file is parsed to detect the source package name, the
   distribution and included files
 - the repository name is computed (if not specified in environment)
 - the current published distribution is retreived using APTLY publish
   API to:
   - check it was already manally published a first time
   - check it used a snapshot kind of sources
   - retreive other components source snapshot
 - Upload the changes file and all its included files using APTLY File
   Upload API in a directory named as the source package
 - Include the changes file using APTLY Local Repos API
 - Compute a snapshot name for the repository based on the current date
   and the repository name. Format: YYYYMMDD-HHMMSS-{repository name}
 - Create a snapshot of the repository using APTLY Local Repos API
 - Update the published distribution with this new snapshot as source of
   the specified component (default: main) and keeping other components
   source snapshot.
2022-12-13 20:14:01 +01:00
Benjamin Renard 6d7c03fb3d Fix publishing snapshot
When calling APTLY publish API, we have to pass the distribution name
and not the repository name. Distribution names are now collected from
changes files and a call to the APTLY publish API will be made for all
updated distribution.

Also add a PREFIX parameter to permit to specify the APTLY prefix (and
storage if it need to be specified).
2022-11-30 20:23:41 +01:00
Benjamin Renard 59214019ba Allow to set parameter using environment variables PLUGIN_* or APTLY_* 2022-11-30 20:15:37 +01:00
Benjamin Renard 4529061bc4 Rename entrypoint.py to aptly-publish 2022-11-30 20:13:57 +01:00
Benjamin Renard a450ed9058 Fix install dependencies in pylint test
ci/woodpecker/push/woodpecker Pipeline was successful Details
2022-05-02 16:22:19 +02:00
Benjamin Renard d228660900 Add CI badge to README
ci/woodpecker/push/woodpecker Pipeline failed Details
2022-05-02 16:15:10 +02:00
Benjamin Renard 9813621c3c Add CI configuration for pylint & flake8 tests 2022-05-02 16:14:11 +02:00
Benjamin Renard b0ecbb6fbc Add README 2022-05-02 16:12:52 +02:00
Benjamin Renard 40db466c57 Fix some pylint warnings 2022-05-02 16:12:37 +02:00
Benjamin Renard 909c726c75 Fix snapshot name formating 2022-05-02 16:12:12 +02:00
Benjamin Renard 2b59592819 First release 2022-05-02 00:39:47 +02:00