bilelmoussaoui / bilelmoussaoui/Hardcode-Tray

Inkscape's "--file / -f" Option Has been Dropped

Open
#672 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
890
Forks
59
PR merge metrics
No merged PRs in 30d

Description

**Inkscape 1.0.1** has dropped the `-f` option from its command-line utilities. Now if run with an `-f` option, which `modules/svg/inkscape.py` currently uses, `inkscape` will return an unknown option error and exit.

This error causes the icon conversion to fail, but is not reflected in the output of `hardcode-tray`.

[Link to the Inkscape Wiki](https://wiki.inkscape.org/wiki/index.php/Using_the_Command_Line#Deprecations_and_Replacements)

```
$ inkscape --version
Inkscape 1.0.1 (3bc2e813f5, 2020-09-07)
Pango version: 1.48.0

$ sudo -E hardcode-tray --apply --only tutanota-desktop
[sudo] Password:
Welcome to Hardcode-Tray!
Hardcode-Tray replaces some icons on the binary files of some applications.
Please close all the running applications before running Hardcode-Tray script.
Desktop Environment: Kde
Scaling Factor: 1
Icon Size: 22
Icon Theme: Papirus
Conversion Tool: Inkscape
To Do: Tutanota-Desktop
Applying now..

Tutanota Desktop [####################################] 1/1 100.0% 0.09s
Took 0.09s to finish the tasks

Done, Thank you for using the Hardcode-Tray fixer!
```

(By this time the icon was not actually replaced.)

```
$ sudo -E inkscape -z -f /usr/share/icons/Papirus/22x22/panel/tutanota-desktop-tray.svg -e /opt/tutanota-desktop/resources/icons/logo-solo-red.png
[sudo] Password:
Warning: Option --without-gui= is deprecated
Unknown option -f
```

(Failed again.)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading modules/svg/inkscape.py and the linked Inkscape command-line deprecation guidance to identify the obsolete option. Re-run the conversion command with Inkscape 1.0.1 and hardcode-tray for tutanota-desktop; done means the icon conversion no longer fails with an unknown-option error and the icon is replaced.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux, python
Domain
cli
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.