Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gpu-screen-recorder{,-gtk}: add passthru.updateScript #367552

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

js6pak
Copy link
Member

@js6pak js6pak commented Dec 23, 2024

Closes #359178

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@github-actions github-actions bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10 labels Dec 23, 2024
Copy link
Member

@keenanweaver keenanweaver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't know how to test it locally, but it looks great.

@wegank wegank added the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Dec 23, 2024
@ofborg ofborg bot requested a review from babbaj December 23, 2024 17:44
@keenanweaver
Copy link
Member

5.0.0 is now out: https://git.dec05eba.com/gpu-screen-recorder/

@js6pak
Copy link
Member Author

js6pak commented Dec 31, 2024

There is also gpu-screen-recorder-ui now, which is interesting

@keenanweaver
Copy link
Member

There is also gpu-screen-recorder-ui now, which is interesting

I was just opening a packaging request for this. Looks like someone already did some preliminary work: https://github.com/Nowaaru/nix-diary/tree/6230e94b178924e7455a1dc0d318f50e10c8aec6/modules/gpu-screen-recorder/packages.

The module would probably need to be updated as well.

@js6pak js6pak force-pushed the gpu-screen-recorder/update-script branch from 3981d06 to f48ec9d Compare December 31, 2024 02:51
@wegank wegank removed the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Dec 31, 2024
@keenanweaver keenanweaver added the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Dec 31, 2024
@js6pak js6pak force-pushed the gpu-screen-recorder/update-script branch from f48ec9d to 092f692 Compare February 3, 2025 00:09
@wegank wegank removed the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Feb 4, 2025
Copy link
Member

@keenanweaver keenanweaver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 367552


x86_64-linux

✅ 2 packages built:
  • gpu-screen-recorder
  • gpu-screen-recorder-gtk

@keenanweaver keenanweaver added the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Feb 7, 2025
}:

stdenv.mkDerivation (finalAttrs: {
stdenv.mkDerivation rec {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {

https://discourse.nixos.org/t/avoid-rec-expresions-in-nixpkgs/8293

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using finalAttrs instead of rec for version here would lead to #310373. I don't think there is a consensus on the best solution, but rec works fine here.

url = "https://dec05eba.com/snapshot/gpu-screen-recorder-gtk.git.${finalAttrs.version}.tar.gz";
hash = "sha256-uXbiuA1XPWZVwQGLh47rKzCZSEUEPWqYALqMuCGA7do=";
src = fetchgit {
url = "https://repo.dec05eba.com/${pname}";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
url = "https://repo.dec05eba.com/${pname}";
url = "https://repo.dec05eba.com/gpu-screen-recorder-gtk";

#277994

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rec being constant doesn't introduce any overriding traps here, so whether you use ${pname} or a literal value is a subjective choice. Imo this is nicer because it can be shared across all gpu-screen-recorder-* packages.

Comment on lines 71 to 75
postPatch = ''
substituteInPlace extra/gpu-screen-recorder.service \
--replace-fail "ExecStart=gpu-screen-recorder" "ExecStart=$out/bin/gpu-screen-recorder"
'';

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is included in the by-name commit

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch! While we are here, mind reviewing #367548? :)

@js6pak js6pak force-pushed the gpu-screen-recorder/update-script branch from 092f692 to 8b1deb5 Compare February 8, 2025 20:34
@wegank wegank removed the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Feb 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants