Commit graph

17 commits

Author SHA1 Message Date
Stefan Hansson
6a1f7a1623
CI: clarify which commit to put [ci:ignore-count] in (MR 5126)
I've seen confusion about this in the past where people would find it
unclear which commit to put this in.
2024-05-13 16:16:18 +02:00
Stefan Hansson
79b8de8483
CI: replace lots of print statements with a single one (MR 5126)
This way it's easier to edit the text.
2024-05-13 16:16:18 +02:00
Clayton Craft
c63e05246f
ci/common: use gitlab CI target branch in get_upstream_branch (MR 5082)
This prefers gitlab CI's target branch from the env, and falls back to
the old target branch detection mechanism (using pmaports.cfg, etc) if
it's not set. This fixes CI in gitlab where the target branch is
something different than expected, e.g. if using stacked branches.

[ci:skip-build]: already built successfully in CI
2024-05-01 00:58:32 +02:00
Clayton Craft
a263494c1c
ci: fix failure with check_changed_aports when testing new aport
Apparently some callers of `get_package_version` expect it to return
None if a package wasn't found...  e.g. when CI is testing a branch that
introduces a new aport and it's trying to get the upstream version for
it, which doesn't exist.

This leads to a spectacular crash in CI:

      upstream = get_package_version(args, package, commit, False)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/clayton/src/pmaports/./.ci/lib/check_changed_aports_versions.py", line 47, in get_package_version
        return parsed["pkgver"] + "-r" + parsed["pkgrel"]
               ~~~~~~^^^^^^^^^^
    TypeError: 'NoneType' object is not subscriptable

When I refactored this method in 07812a918 I goofed up and changed this
behavior, so let's restore it to fix the crash.
2024-04-23 17:59:30 -07:00
Arnav Singh
deb676fba2
ci/check_changed_aports_ver: fix pkgrel check (MR 5061)
The apkbuild parser returns `pkgrel` key as a `str`, not an `int`,
so the `!= 0` check would always succeed even if the file set it to `0`.

[ci:skip-build]: already built successfully in CI
2024-04-23 10:43:03 -07:00
Clayton Craft
970bc34c45
ci/check_changed_aports_ver: add tests for new dev pkg rules (MR 4994)
[ci:ignore-count]

[ci:skip-vercheck]
[ci:skip-build]: already built successfully in CI
2024-04-22 16:37:41 -07:00
Clayton Craft
07812a9189
ci/check_changed_aports_ver: move apkbuild reading from get_version (MR 4994)
This allows reusing the logic to read apkbuild contents in future
methods
2024-04-22 16:37:41 -07:00
Clayton Craft
284fd42c0a
ci: add test for validating pkgver for device packages (MR 4994) 2024-04-22 16:37:41 -07:00
Vitaliy Ognev
5cef8d31ca
ci: fix format specifier typo in wiki script (MR 5038) 2024-04-16 09:05:05 +03:00
Newbyte
ca976d487c
CI: CI runs for three hours, not one hour (MR 4135)
In 11682fb0ab, the timeout was set to 10
hours. This means that the CI no longer just runs for one hour. However,
we are still limited by GitLab's runners which only give us three hours
of CI time per job, so given the status quo, this is the most likely
duration for someone who hasn't set up their own CI runners.
2023-05-30 09:12:52 +02:00
Oliver Smith
cfb582cba0
CI: kconfig: don't print unrelated warnings (MR 3961)
Run the "pmbootstrap kconfig check" only on the kernels that have been
modified.

[ci:skip-build] already built successfully in CI
2023-03-22 09:40:39 -07:00
Oliver Smith
eb37732514
CI: adjust scripts to pass shellcheck (MR 3960) 2023-03-20 09:30:55 +01:00
Oliver Smith
d502d02a0b
CI: bump copyright to 2023 2023-01-26 08:40:40 +01:00
Oliver Smith
245d41d7c5
CI scripts: fix typo in URL (MR 3655)
Note that the URLs in these scripts are not only for information, but
they are also used as marker by pmbootstrap so it knows these are
compatible with 'pmbootstrap ci'. I just fixed the typo in the
pmbootstrap code as well and made a new release, use pmbootstrap 1.50.0
or above to have it recognize these scripts with 'pmbootstrap ci' again.
2022-11-20 16:50:42 +01:00
Oliver Smith
6dbe4fdc31
CI: move_logs.sh: put in .ci/lib (MR 3608) 2022-11-17 19:10:56 +01:00
Oliver Smith
da52dace85
CI: adjust .ci/common.py users to pmbootstrap ci (MR 3608)
Adjust all CI scripts that make use of .ci/common.py to
'pmbootstrap ci'. Move all scripts that are not direct entry points to
running CI scripts to .ci/lib.

Comment out the dtb check, as it is failing. Apparently it didn't run
properly before. Let's fix this after this CI change is done.
2022-11-17 19:10:56 +01:00
Oliver Smith
a2f75963bf
CI: wiki: adjust for 'pmbootstrap ci' (MR 3608)
Add a wrapper .ci/wiki.sh, that pmbootstrap ci can run and use it in
gitlab-ci.yml. Add a .ci/lib/gitlab_prepare_ci.sh script that makes a
user available with sudo, as expected by the pmbootstrap ci compatible
scripts. Set up binfmt_misc too while at it, it will be needed for
running pmbootstrap.

The next patches will adjust the rest of the CI scripts and move the old
scripts in the .ci/lib dir, so only the scripts that should be called
directly are in the .ci dir.

Related: https://postmarketos.org/pmb-ci
2022-11-17 19:10:56 +01:00