Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,19 @@ The following people have contributed to Anki: [CONTRIBUTORS](./CONTRIBUTORS)
If you'd like to try development builds of Anki but don't feel comfortable
building the code, please see [Anki betas](https://betas.ankiweb.net/).

## Linux Desktop Integration

On any Linux desktop that follows the [XDG spec](https://specifications.freedesktop.org/desktop-entry-spec/latest/) (GNOME, KDE, XFCE, Cinnamon, MATE, and others), you can install a launcher entry for the development build so it appears in your app grid and can be pinned to the dock.

```bash
# From the repo root
sed "s|ANKI_SRC|$(pwd)|g" tools/anki-dev.desktop \
> ~/.local/share/applications/anki-dev.desktop
update-desktop-database ~/.local/share/applications/
```

Then open your app grid, search for **Anki (dev)**, right-click, and choose **Add to Favourites** (GNOME) or the equivalent for your desktop.

Comment on lines +30 to +42

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The current way anki is doing this is already integrated into the desktop.

Aside from that, I don't think we should be teaching people how to pin an icon. That differs for every OS and WM and could change with major versions of OSs or WMs.

## License

Anki's license: [LICENSE](./LICENSE)
9 changes: 9 additions & 0 deletions tools/anki-dev.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[Desktop Entry]
Name=Anki (dev)
Comment=Spaced repetition flashcard program
Exec=bash -c 'cd ANKI_SRC && just run'
Icon=ANKI_SRC/qt/aqt/data/qt/icons/anki.png

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The icon at qt/aqt/data/qt/icons/anki.png isn't the desktop icon. And your image shows that your PR creates an inconsistency, because anki now has a settings icon in the app overview.

Terminal=false
Type=Application
Categories=Education;
StartupWMClass=anki
Comment on lines +1 to +9

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Even if an additional .desktop file would make sense (I don't see how), generating one with claude isn't advised. Just make a copy of the already existing file and update accordingly. Your version just causes inconcistencies.

https://github.com/ankitects/anki/blob/35de142312afedf023ebbbe24599afa1e44f300e/qt/installer/linux-template/%7B%7B%20cookiecutter.format%20%7D%7D/%7B%7B%20cookiecutter.app_name%20%7D%7D/anki.desktop

Loading