Comments (12)
I've been testing on a clean VM but apparently kept state between two tests. You're right -- after putting the desktop file in ~/.local/share/applications
you still need to run xdg-mime default zotero.desktop x-scheme-handler/zotero
for urls to work in FF. And it does look like the apt installation process does that for the mimetypes listed in the desktop file automatically.
from zotero-standalone-build.
It does (just tried again on a clean install of Ubuntu 20.04). It looks like the apt tools invoke xdg-mime default
in some way.
from zotero-standalone-build.
Oh, so is it only on an apt install? The presence of the zotero.desktop file with that line in ~/.local/share/applications won't do it?
I'm basically asking if there's any reason to add this line to the stock desktop file in the tarball.
from zotero-standalone-build.
Turns out no; as long as the desktop file is in either /usr/share/applications
or ~/.local/share/applications
, xdg will find it. My debs were just putting them in /usr/shar/applications
. Zotero has an install script that patches the desktop file, right? Might want to ln
it to ~/.local/share/applications
; ln
will work (just tested).
edit: in which case the line in zotero.desktop
does actually help:
$ xdg-mime query default x-scheme-handler/zotero
zotero.desktop
which works for any of the other mimetypes registered in de desktop file.
from zotero-standalone-build.
I'm saying that I added your MimeType line to the official zotero.desktop, did a normal ln -s
into ~/.local/share/applications
as per our official instructions, and I couldn't find a context where that did anything with the MimeType line.
What are you suggesting I do differently? How are you testing whether it works?
from zotero-standalone-build.
xdg-mime query default x-scheme-handler/zotero
shows zotero.desktop
for me, so I guess it's doing something, but a zotero://select link in Firefox (at least from a file:// URL) doesn't work, nor is Zotero offered when I go to Open With Other Application for a RIS file. So in what way is this doing something for you?
from zotero-standalone-build.
Except for file extensions it still does not work; looks like ris
eg is not known by default.
from zotero-standalone-build.
In my experience, you need to run update-desktop-database
after installing a new desktop file. This updates the cache database containing the list of MIME types handled by desktop files. If you use desktop-file-install
to install the file you can also use the --rebuild-mime-info-cache
option, but you may have to run update-desktop-database
regardless.
I would assume that running xdg-mime default
is something a user would do if there were multiple different applications handling the same type and that it should not be necessary if Zotero is the only application registered for the URL scheme.
To register unknown MIME types you can use xdg-mime install
with a short XML file describing the type. Or copy the files yourself, e.g., to ~/.local/share/mime
and update-mime-database
afterwards. I think if your desktop file references the new MIME types you need to do this before update-desktop-database
.
from zotero-standalone-build.
Yeah looks like it, means I have to re-add the postinst
script.
from zotero-standalone-build.
Hi, anyone knows if this functionality is working? Also is there any doc on how it was meant to work -- couldn't find anything, except some references to zotero://
in the source code.
./zotero-bin --help
doesn't show -url
flag. Also, not sure if it was meant to be --url
?
Either way, it doesn't really work -- grepped in the code for some examples of
zotero://
URLS, like zotero://debug
, but when I run ./zotero-bin --url zotero://debug
, nothing happens? Or am I doing something wrong?
I'm using Zotero Beta, in case it matters.
from zotero-standalone-build.
@karlicoss this blog post describes some context that might be useful
from zotero-standalone-build.
I played around with x-scheme-handler/zotero
in the context of wshanks/Zutilo#207 (opening zotero://
item links) and found that it did make a difference, so I would recommend adding it to zotero.desktop
in this repo.
from zotero-standalone-build.
Related Issues (20)
- Outdated LibreOffice integration submodule HOT 3
- fx-compat: Apple Silicon source build can't load Mac Word dylib HOT 1
- Fix bootstrapped plugins getting disabled on upgrade from Zotero 6 to 7
- Remove Firefox profile-downgrade check
- Update hardened-runtime entitlements for fx102
- Update Firefox to 102.9.0esr HOT 1
- Packaging for Alpine Linux HOT 3
- Building Zotero : fetch_pdftools error HOT 1
- To choose the program for openning a jpg file HOT 1
- Dark theme issue on Linux HOT 2
- Windows: Update version number in Add/Remove Programs on update HOT 4
- Support minimize to tray on Linux HOT 3
- Blank context menus HOT 1
- Fetching XUL runner gets stuck when modifying omni HOT 1
- npm run build errors on arm64 HOT 1
- Replace use of wget with curl
- CFBundleShortVersionString should only contain numbers and periods
- Fix macOS bundle version strings for betas
- Right-click -> Copy in Error Console doesn't copy anything (on macOS only?)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zotero-standalone-build.