Code Monkey home page Code Monkey logo

Comments (10)

SquareBottle avatar SquareBottle commented on August 15, 2024 1

Thanks for thinking about how you'd do it. Even if you don't, I appreciate the consideration – especially since you're already babysitting the entire project until somebody more interested comes along.

For what it's worth, I'll try to bring up your situation in forums where people are likely to be interested. It's not related to the feature request at hand, but just as a thought: if it's easy, maybe you could have a message appear on updates that says something like, "The update was successful. Also, the original maintainer has been gone for a while, and I've been handling things because there were so many requests. But I don't actually use this myself, and my intention was only to keep the ship afloat until a more interested captain comes along. If you use ZotHero and have the programming knowledge to help, then please come forward!" (In your own words, of course.)

Anyway, thanks again for everything.

from zothero.

SquareBottle avatar SquareBottle commented on August 15, 2024

Nevermind. This is in the instructions. It's at the bottom in the All Settings section.

I suggest mentioning this information in the Citation Styles section. That's where I expected it to be, so others might expect the same. At the very least, I think it'd be useful to tell readers to go to the All Settings section for the info.

from zothero.

SquareBottle avatar SquareBottle commented on August 15, 2024

Bahh! That doesn't solve it! Specifically, changing the variable in the workflow (as per the instructions from the All Settings section) changes both!

On the bright side, I have a better understanding of things now. Only one citation style may be used, and that variable is where it's set. Each citation style has a citation format and a bibliography format. Note that citation styles are not the same thing as citation formats. (This can get confusing since the terminology doesn't seem to be used consistently by Zotero, ZotHero, or anyone as far as I can tell.)

So, in order to have the desired behavior, a new feature would need to be added in the form of a new variable. The idea is to go from the functionality conveyed by this:

Variable Meaning
ATTACHMENTS_DIR Path to your Zotero attachments. Read from Zotero's config by default.
CITE_STYLE Citation style copied by ⌘↩ and ⌥↩
LOCALE Locale for citations. Default: en-US (US English).
ZOTERO_DIR Path to your Zotero data. Read from Zotero's config by default.
COPY_CITEKEY_MOD Set to copy Better BibTeX citekey instead of CSL citation/bibliography.

To something like this:

Variable Meaning
ATTACHMENTS_DIR Path to your Zotero attachments. Read from Zotero's config by default.
CITE_STYLE Citation style copied by ⌘↩ and ⌥↩. When BIB_STYLE is not blank, this variable will instead only control what is copied by ⌥↩.
BIB_STYLE When this isn't blank, it will take control of what is copied by ⌘↩.
LOCALE Locale for citations. Default: en-US (US English).
ZOTERO_DIR Path to your Zotero data. Read from Zotero's config by default.
COPY_CITEKEY_MOD Set to copy Better BibTeX citekey instead of CSL citation/bibliography.

This functionality would be handy for people like me who want to use the RTF Scan citation format for writing papers and Chicago (notes) bibliography format when writing for the web.

Thank you for considering.

from zothero.

deanishe avatar deanishe commented on August 15, 2024

Note that citation styles are not the same thing as citation formats. (This can get confusing since the terminology doesn't seem to be used consistently by Zotero, ZotHero, or anyone as far as I can tell.)

Yeah. I really know nothing about this whole business of citing stuff. I only wrote the workflow because the existing one was borked and abandoned, and a lot of Alfred users needed a sensible replacement. I'm still hoping someone who knows and cares about this kind of thing will step in and take over maintaining it.

a new feature would need to be added in the form of a new variable

It's nowhere near as simple as just adding a new variable, I'm afraid. The general architecture of the workflow assumes one CSL style. It would require a lot of work to implement different ones for citations and bibliographies.

from zothero.

SquareBottle avatar SquareBottle commented on August 15, 2024

Yeah. I really know nothing about this whole business of citing stuff. I only wrote the workflow because the existing one was borked and abandoned, and a lot of Alfred users needed a sensible replacement. I'm still hoping someone who knows and cares about this kind of thing will step in and take over maintaining it.

You're a saint for taking over until somebody more familiar with citation comes along!

It's nowhere near as simple as just adding a new variable, I'm afraid. The general architecture of the workflow assumes one CSL style. It would require a lot of work to implement different ones for citations and bibliographies.

Hmmmmm... Would it be easier to add a second citation style then?

Forgive me if this is too simplistic, I'm not a programmer at all. But what if you copy all the code related to the CITE_STYLE variable, paste it in a new code file, and use find-and-replace to change every instance of CITE_STYLE to BIB_STYLE?

Even if it works the way I'm imagining it in my head, it probably wouldn't do 100% of what needs to be done. For example, you'd need to tell the other ZotHero code files to incorporate the new one and assign new keyboard shortcuts (perhaps simply adding the shift key). But hey, if it gets you 90% of the way toward a solution, then that's pretty good right?

Assuming I'm off by a mile, what do you think would be the easiest way to deliver the functionality I described?

from zothero.

deanishe avatar deanishe commented on August 15, 2024

Would it be easier to add a second citation style then?

That's basically exactly what you're asking for.

Even if it works the way I'm imagining it in my head

It doesn't. It's a lot more complicated than just duplicating some code and running find-and-replace on it.

what do you think would be the easiest way to deliver the functionality I described?

Significant sections of the workflow need rewriting to handle multiple styles at the same time, instead of just one.

from zothero.

SquareBottle avatar SquareBottle commented on August 15, 2024

Ahh, alright. Sorry.

from zothero.

deanishe avatar deanishe commented on August 15, 2024

I'll have a think about it, and add it if it's not too much effort.

But tbh, I can't really be arsed spending much time on this workflow, and it's really low priority because I personally have zero use for it.

I've tagged this issue as "help wanted". Perhaps someone else is interested in adding the feature.

from zothero.

deanishe avatar deanishe commented on August 15, 2024

For what it's worth, I'll try to bring up your situation in forums where people are likely to be interested.

Thanks. I'm sure the workflow would benefit from a maintainer that actively uses it.

from zothero.

masteranza avatar masteranza commented on August 15, 2024

Thanks. I'm sure the workflow would benefit from a maintainer that actively uses it.

@deanishe indeed. Would you mind sharing build script for this workflow?

from zothero.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.