Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

pdfinvert.rb does not work if Inkscape can not access /tmp

Open
#1 12 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
ruby
Domain
cli

Research direction

Start by reproducing ruby pdfinvert.rb sheet01.pdf sheet01_inv.pdf with the supplied archive, then inspect pdfinvert.rb around line 222 and the Inkscape-related temporary-file handling. Done means the command completes successfully and produces the inverted PDF when Inkscape cannot access /tmp.

Written by the indexing model from the issue text.

Description

I really appreciate the work you put in the pdfinvert script. I searched long on the internet to find sth useful to invert pdf 😀
But I get an exception when executing. Here is the debug output:

▶ ruby pdfinvert.rb sheet01.pdf sheet01_inv.pdf          
Exception `Gem::LoadError' at /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/dependency.rb:319 - Could not find 'parallel' (>= 0) among 15 total gem(s)
Checked in 'GEM_PATH=/Users/renekud/.gem/ruby/2.3.0:/Library/Ruby/Gems/2.3.0:/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/gems/2.3.0', execute `gem env` for more information
Exception `Errno::ENOENT' at pdfinvert.rb:222 - No such file or directory @ rb_sysopen - input_0001.svg
pdfinvert.rb:222:in `initialize': No such file or directory @ rb_sysopen - input_0001.svg (Errno::ENOENT)
	from pdfinvert.rb:222:in `open'
	from pdfinvert.rb:222:in `invert'
	from pdfinvert.rb:354:in `block in <main>'
	from pdfinvert.rb:353:in `each'
	from pdfinvert.rb:353:in `rescue in <main>'
	from pdfinvert.rb:343:in `<main>'

I have the script in the same directory like the pdf that I want to invert. It would be wonderfull if we could fix this. Sadly I never did sth in ruby :D
Here are the files of the /tmp/pdfinvert folder:
pdfinvert_sheet01.zip

Dominant language
Ruby
Stars
19
Forks
9
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from reitzig/scripts

All issues in reitzig/scripts

Similar issues

More Ruby issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.