Commit Graph

30 Commits

Author SHA1 Message Date
Janne Heß
af69be669f
treewide: Rename nixfmt to nixfmt-classic (#300468)
* treewide: Rename nixfmt to nixfmt-classic

* Update pkgs/top-level/aliases.nix

Co-authored-by: Silvan Mosberger <github@infinisil.com>

---------

Co-authored-by: Silvan Mosberger <github@infinisil.com>
2024-04-02 20:47:13 +02:00
networkException
9e33ff7183
chromium: use hashes in upstream-info.nix for tarballs in update script
this patch teaches the update script to use the hash for a recompressed
chromium source tarball from the upstream-info.nix file instead of
recompressing a new tarball for an already hashed version.
2024-02-14 02:31:26 +01:00
networkException
5eb227c31f
chromium: cache chromium tarball hashes in update script
this patch introduces an in memory cache for the result of hashing a
chromium release tarball after recompressing and pruning it.

previously updating chromium and ungoogled-chromium to the same chromium
version would result in the expensive recompression happening twice.
2024-02-14 00:14:47 +01:00
networkException
1940f32366
chromium: add update script command to use unreleased ungoogled-chromium
this patch adds a new subcommand to the update script

```
update.py ungoogled-rev <rev>
```

to update to an unreleased version of ungoogled-chromium by referencing
a git ref from the ungoogled-chromium repository (like a commit hash in an
update pull request).
2023-11-29 22:23:46 +01:00
emilylange
59719f787e
chromium{Beta,Dev},google-chrome-{beta,dev}: drop
This is mainly due to the lack of maintenance in nixpkgs.
`google-chrome-{beta,dev}` depend on `chromium{Beta,Dev}`'s version
info.

`chromium{Beta,Dev}` are rarely updated and explicitly blocklisted by
`hydra.nixos.org`, meaning they are almost always outdated and not
cached in `cache.nixos.org`.

`chromium{Beta,Dev}` were intended to fix the build derivation of each
new major release (if something broke) *before* stable reached that
new major release.
Allowing for fast bumps in nixpkgs, especially if the stable bump
contains very important critical security fixes.

Something that can easily be replicated by using an early-stable release
or by manually entering a dev/beta version string in stable's
`upstream-info.nix`.

This resolves exposing end-users to outdated and vulnerable
`google-chrome-{beta,dev}` and `chromium{Beta,Dev}` versions.
2023-10-28 22:55:18 +02:00
networkException
6e4796d619
chromium,electron: always output sri hashes from update scripts
this patch changes the update script to always output sri hashes
for all hashes written to chromium's `upstream-info.nix` and
electron's `info.json`. the keys have also been renamed from `sha256`
to `hash`.
2023-10-21 15:16:58 +02:00
emilylange
5766d04f96
chromium: fix update.py script
This is needed as we very recently started re-compressing the upstream
`tar.xz` to stay under the closure size limit of hydra.nixos.org.
2023-10-20 02:19:47 +02:00
networkException
65e801cb43
chromedriver: fix update script
The apis for getting the lastest chromedriver release have changed
with M115.

See https://chromedriver.chromium.org/downloads/version-selection#h.4wiyvw42q63v
See f61f5a8a40
2023-08-04 17:13:41 +02:00
emilylange
68c59791fb
chromium,ungoogled-chromium: fix ofborg maintainer pings
ofborg uses `builtins.unsafeGetAttrPos` internally, to figure out which
maintainers need to be pinged.

e.g:
`builtins.unsafeGetAttrPos "version" drv`

When using a `.json` file containing the version via `lib.importJSON`,
this will always return `null` and thus leading to no pings at all.

This commit works around this, resulting in properly working pings
for any changes to the upstream-info file.

A similar thing has been done for element-{web,desktop} in the past.
2023-08-02 12:17:42 +02:00
networkException
81a44e02bc
ungoogled-chromium: Only use linux stable tags
ungoogled-chromium releases generally follow the chromium stable channel,
however as the patchset targets Linux, macOS and Windows, a release might
not always be intended for being packaged in nix. This patch patches the
update script to filter ungoogled-chromium releases by them being available
as stable releases for Linux.
2023-04-21 21:36:36 +02:00
networkException
ab757c51f5
ungoogled-chromium: update repo links to ungoogled-software organisation
The main repository has moved from the Eloston user to the
ungoogled-software organisation.
2023-04-21 21:36:36 +02:00
networkException
93357bed06
chromium: use versionhistory.googleapis.com over omahaproxy.appspot.com
Version information previously available at omahaproxy.appspot.com will
have to be retrieved from versionhistory.googleapis.com in the future.

See https://groups.google.com/a/chromium.org/g/chromium-dev/c/uH-nFrOLWtE/m/PhUj_inyAQAJ
See https://github.com/ungoogled-software/ungoogled-chromium/pull/2260
2023-04-21 21:36:35 +02:00
Konstantin Alekseev
c02b06d612 chromedriver: fix darwin aarch64 2022-10-08 16:15:57 +03:00
Michael Weiss
3d50284bb2
chromedriver: Disable on aarch64-darwin
chromedriver_mac64_m1.zip is currently not available anymore and I do not have time to look into it:
path is '/nix/store/zhz7hrk94dc0dn7a42czhd1nz9142826-chromedriver_mac64.zip'
nix-prefetch-url https://chromedriver.storage.googleapis.com/106.0.5249.61/chromedriver_mac64_m1.zip
error: unable to download 'https://chromedriver.storage.googleapis.com/106.0.5249.61/chromedriver_mac64_m1.zip': HTTP error 404

       response body:

       <?xml version='1.0' encoding='UTF-8'?><Error><Code>NoSuchKey</Code><Message>The specified key does not exist.</Message><Details>No such object: chromedriver/106.0.5249.61/chromedriver_mac64_m1.zip</Details></Error>
2022-10-05 20:26:09 +02:00
Samuel Gräfenstein
1122130c6f
ungoogled-chromium: inherit upstream's build flags
This ensures that our build flags for ungoogled-chromium will remain
up-to-date with upstream's defaults (also important for avoiding build
errors).

Co-authored-by: Michael Weiss <dev.primeos@gmail.com>
2022-03-06 15:11:19 +01:00
Konstantin Alekseev
6e0a2c1c54 chromedriver: add support for aarch64-darwin 2021-12-30 23:23:45 +03:00
Michael Weiss
b054a8594a
chromium: update.py: Download files from the main repository
The tag 98.0.4710.4 is missing on the official GitHub mirror. As a
result the download of the DEPS file was failing (HTTP Error 404: Not
Found). Using the upstream repository is obviously better anyway, it's
just less obvious how to fetch a file from there (?format=TEXT).
2021-11-20 22:29:29 +01:00
Michael Weiss
9bc2d82b55
chromium: get-commit-message.py: Support specifying a version
This makes the usage from update.py more robust.
It also adds a workaround for [0] which currently lacks a title.

[0]: https://chromereleases.googleblog.com/2021/08/the-stable-channel-has-been-updated-to.html
2021-08-04 17:55:21 +02:00
Michael Weiss
e143dc53b2
chromium: update.py: Implement automatic committing of the updates
This functionality saves some unnecessary work.
2021-08-04 00:29:34 +02:00
Michael Weiss
268600e6b7
ungoogled-chromium: 87.0.4280.141 -> 88.0.4324.104
Unfortunately this requires a crazy hack to support building with
Google's proprietary Widevine DRM technology as that requires fetching
the Google Chrome sources (see also 86ff1e45ce).
The hack is required because ungoogled-chromium doesn't always use tags
that correspond to a Google Chrome release.
2021-01-30 19:22:22 +01:00
Michael Weiss
863982d272
chromium: Fix the version comparison in print_updates()
I forgot that string comparison isn't enough because e.g.:
>>> "89.0.4389.9" < "89.0.4389.23"
False

distutils.version.LooseVersion is undocumented but it works and is
already available so why not use it:
>>> LooseVersion("89.0.4389.9") < LooseVersion("89.0.4389.23")
True
2021-01-28 15:45:00 +01:00
Michael Weiss
76fe724675
chromium: Extend update.py to print a summary of the updates
As a first step to automate the commit messages as well.
2021-01-14 21:02:16 +01:00
Michael Weiss
86ff1e45ce
ungoogled-chromium: Support enableWideVine=true
Building with Google's proprietary Widevine DRM technology requires
fetching the Google Chrome sources.
2020-12-22 13:35:40 +01:00
Michael Weiss
94bee10904
ungoogled-chromium: Support automatic updates via update.py 2020-12-18 19:10:45 +01:00
Michael Weiss
9b846b9600
chromium: Improve update.py (documentation + linting fixes) 2020-12-18 19:10:44 +01:00
Michael Weiss
240a8f746e
ungoogled-chromium: Move ungoogled-src.nix into upstream-info.json
This also adds a dedicated channel for ungoogled-chromium that enables
us to update ungoogled-chromium independently of chromium.
TODO: Automate ungoogled-chromium updates via update.py (currently it
needs to be updated manually).

Note: Unfortunately this changes the ungoogled-chromium derivation
because common.nix passes the channel as an argument to
stdenv.mkDerivation (this makes it more difficult to verify this commit
but the result should remain the same).
2020-12-10 17:41:22 +01:00
Michael Weiss
6aea53c3ce
chromedriver: Switch to Chromium's upstream-info.json (#105054)
This enables automatic updates and fixes #85629.
2020-11-27 12:38:07 +01:00
Michael Weiss
d7f5386474
chromium: Extend update.py to automatically update gn
The gn version depends on the channel and new gn versions aren't always
backward compatible. Therefore we should also include it in
upstream-info.json (I've scoped it under "deps" as we'll likely have to
add more like this in the future).
2020-11-03 20:00:25 +01:00
Michael Weiss
ceb3acfa8b
chromium: update.py: Keep the channel order consistent
This makes Git diffs way easier to read.
Using sort_keys=True is usually better but with this implementation the
output is a bit nicer to read IMO.
2020-09-10 12:30:03 +02:00
Alyssa Ross
de69b705d2 chromium: replace update.nix with Python impl
update.nix was a huuuuge hack, abusing checksum collisions, etc., and
was extremely difficult to read and maintain, especially because
values from update.nix were also used in the derivations themselves!

I've replaced this with an implementation in Python, which I chose for
readability.  Rather than generating Nix, I chose to
generate JSON, since Python can do that in the standard library and
Nix can read it.

I also set update.py as an updateScript, so Chromium can now
automatically be updated!

Fixes: https://github.com/NixOS/nixpkgs/issues/89635
2020-09-05 11:20:13 +02:00