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

stirling-pdf: init at 0.22.3 #283305

Merged
merged 1 commit into from
Apr 3, 2024
Merged

stirling-pdf: init at 0.22.3 #283305

merged 1 commit into from
Apr 3, 2024

Conversation

TomaSajt
Copy link
Contributor

@TomaSajt TomaSajt commented Jan 23, 2024

Description of changes

Closes #282169

This PR adds 1 package: stirling-pdf

This is a gradle app, so it got the typical gradle treatment: prefetch deps, then use them as a fake maven repository

The package generates a signed jar file, which is apparently not supported by the backend of stripJavaArchivesHook, so I had to use the built-in gradle way of fixing the timestamps of the jar files.

Other than this patch there's one which removes the spotless, because it couldn't resolve all its dependencies correctly. There's another one, which removes the timestamp header from a .properties file

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/)
  • 24.05 Release Notes (or backporting 23.05 and 23.11 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.

@EricTheMagician
Copy link
Contributor

I've tested it and it works.
The only thing that I see is:

Feb 08 16:05:03 mini-nix stirling-pdf-start[3902677]: 16:05:03.772 [main] INFO  s.s.S.config.EndpointConfiguration - Disabling pdf-to-book
Feb 08 16:05:03 mini-nix stirling-pdf-start[3902677]: 16:05:03.772 [main] INFO  s.s.S.config.EndpointConfiguration - Disabling book-to-pdf

I don't know if I care. I'm just happy to try it out!

Thank you so much for packaging it!

@TomaSajt TomaSajt force-pushed the stirling-pdf branch 2 times, most recently from 438be55 to f0b0f37 Compare February 9, 2024 08:01
@TomaSajt TomaSajt changed the title stirling-pdf: init at 0.20.0 stirling-pdf: init at 0.20.2 Feb 9, 2024
@TomaSajt TomaSajt force-pushed the stirling-pdf branch 2 times, most recently from cfed41f to bded1c9 Compare March 20, 2024 22:15
@TomaSajt TomaSajt changed the title stirling-pdf: init at 0.20.2 stirling-pdf: init at 0.22.3 Mar 20, 2024
@eliandoran
Copy link
Contributor

Result of nixpkgs-review pr 283305 run on x86_64-linux 1

1 package built:
  • stirling-pdf

Copy link
Contributor

@LordGrimmauld LordGrimmauld left a comment

Choose a reason for hiding this comment

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

piping into sh looks weird though i don't claim it can't work. Everything else makes sense.

pkgs/by-name/st/stirling-pdf/package.nix Show resolved Hide resolved
| perl -pe 's#(.*/([^/]+)/([^/]+)/([^/]+)/[0-9a-f]{30,40}/([^/\s]+))$# ($x = $2) =~ tr|\.|/|; "install -Dm444 $1 \$out/$x/$3/$4/$5" #e' \
| sh
# weird dependency resolution fix
ln -s $out/com/squareup/okio/okio-jvm/3.6.0/okio-jvm-3.6.0.jar $out/com/squareup/okio/okio/3.6.0/okio-3.6.0.jar
Copy link
Contributor

Choose a reason for hiding this comment

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

How maintainable is this bit hardcoding versions here in case upstream dependencies change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's going to return an error if the dependencies change, so I can easily just change this version accordingly.

Copy link
Contributor

@drupol drupol left a comment

Choose a reason for hiding this comment

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

LGTM

@drupol drupol merged commit 146761d into NixOS:master Apr 3, 2024
23 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stirling PDF
6 participants