Comments (14)
Hi @apc - it definitely should work as you expect. The first screenshot on the README is what you should see if you have which-key
setup and after invoking embark-act
.
First, questions:
Did you set the embark variable mentioned in the README:
https://github.com/bdarcus/bibtex-actions#basic
It occurs to me it's possible that section is too brief ATM.
If, as I assume, yes, then two additional questions:
- do you have marginalia installed and active? I think this is necessary for embark to be able to associate these commands with that keymap.
- do you have embark configured to load the menus? You may have to do something there.
Once setup, it should just work.
BTW, there's some handy test scripts at the selectrum repo, which will setup this up for you to test with emacs -Q.
Edit: link https://github.com/raxod502/selectrum/tree/master/test
You should just be able to install bibtex-actions
from MELPA from there and be good to go for testing.
Can you take a look this, and let me know if you think I need to add to that README section, and ideally suggest what I should add?
from citar.
PS: you don't actually need to deactivate ivy in your config. You just need to turn it off, and turn on selectrum, etc.
from citar.
Hi @bdarcus, thanks for your quick reply! This is my current setup for bibtex-actions
:
(use-package bibtex-actions
:demand t
:config
(setf (alist-get 'bibtex embark-keymap-alist) 'bibtex-actions-map)
(setq bibtex-completion-bibliography '("~/bib/apcmain.bib")))
I figured out that if I type C-h
after calling embark-act
I see the list of available bindings. Before doing that, all I see is this:
This may well be the intended behavior. Coming from ivy-bibtex
, though, I was used to seeing the menu of options when calling ivy-dispatching-done
from the list of bib
entries. Maybe that's why I got confused?
I'll think about your question re: the README section. In the meantime, here are a few thoughts.
- I had previously set all variables from
bibtex-completion
(includingbibtex-completion-bibliography
) in myuse-package
declaration forbibtex
. I suspect most people trying outbibtex-actions
may have set those values in their init. I could have used a reminder to move all those settings to theuse-package
declaration forbibtex-actions
. So, something like: "You may have already set values for many of thebibtex-completion
variables thatbibtex-actions
relies on; you want to make sure those variables are set the way you want before you first call any of thebibtex-actions-
commands." - A sample
use-package
declaration, listing all the values that are needed for most of the actions to work as expected (bibtex-completion-library-path
,bibtex-completion-bibliography
, etc.) would be nice to have. - It might be helpful to explain that you need to have
embark
loaded for the setting ofembark-keymap-alist
not to give an error. (So, perhaps having:after embark
in the example declaration?) - Finally, just a line saying "to see the list of available
bibtex-actions
, callembark-bindings
" would have been super helpful. (Or perhaps something much like this section of thehelm-bibtex
documentation?)
from citar.
PS: when I call embark-bindings
I see a list of available actions for the selected entry, but it's embedded in this much longer listing of actions available. Is there some way of just seeing bibtex-actions
related bindings?
from citar.
PS: when I call
embark-bindings
I see a list of available actions for the selected entry, but it's embedded in this much longer listing of actions available. Is there some way of just seeingbibtex-actions
related bindings?
You shouldn't need to call embark-binding
if this is setup right.
Does something like this setup, from the selectrum test scripts, work for you?
https://github.com/raxod502/selectrum/blob/master/test/selectrum-orderless.el
from citar.
I'll think about your question re: the README section. In the meantime, here are a few thoughts.
Thank you!
What do you think about explicitly including how to get this running using the selectrum test scripts, and then moving the more detailed examples to the wiki?
from citar.
I'll think about your question re: the README section. In the meantime, here are a few thoughts.
Thank you!
What do you think about explicitly including how to get this running using the selectrum test scripts, and then moving the more detailed examples to the wiki?
That would be great!
from citar.
PS: when I call
embark-bindings
I see a list of available actions for the selected entry, but it's embedded in this much longer listing of actions available. Is there some way of just seeingbibtex-actions
related bindings?You shouldn't need to call
embark-binding
if this is setup right.Does something like this setup, from the selectrum test scripts, work for you?
https://github.com/raxod502/selectrum/blob/master/test/selectrum-orderless.el
That helps! I ended up adding
(setq embark-prompter #'embark-completing-read-prompter)
(global-set-key (kbd "M-o") #'embark-act)
and that gave me a much more user-friendly experience. I'd still like to be able to only see the list of bibtex-actions
available, rather than all the options I now see. Do you know if there's an easy way to make that happen?
from citar.
I'd still like to be able to only see the list of
bibtex-actions
available, rather than all the options I now see. Do you know if there's an easy way to make that happen?
I strongly agree!
Two things:
First, I had a recent chat with embark author @oantolin about just this, and he noted it's on his todo.
Would it help for one of us to add an explicit issue @oantolin?
Second, in the meantime, I sort the commands in the menu, so the bibtex-actions
ones come first.
https://github.com/bdarcus/bibtex-actions/wiki/Configuration#which-key
That's for which-key
though; not sure if or how to do that with the default one.
from citar.
BTW, marginalia is also generally useful, beyond its connection to embark.
from citar.
I'd still like to be able to only see the list of
bibtex-actions
available, rather than all the options I now see. Do you know if there's an easy way to make that happen?I strongly agree!
Two things:
First, I had a recent chat with embark author @oantolin about just this, and he noted it's on his todo.
Would it help for one of us to add an explicit issue @oantolin?
Second, in the meantime, I sort the commands in the menu, so the
bibtex-actions
ones come first.https://github.com/bdarcus/bibtex-actions/wiki/Configuration#which-key
That's for
which-key
though; not sure if or how to do that with the default one.
Very helpful! I should have checked the wiki first. Using which-key
is fine by me for now. (I take it the which-key
settings work because bibtex-
appears first when actions are sorted alphabetically, right?)
And yes, I've installed marginalia
as well. I'm still very new to all of this, though, so I'm sure there's plenty for me to learn before I can get things where I wanted.
from citar.
I take it the
which-key
settings work becausebibtex-
appears first when actions are sorted alphabetically, right?)
Right. I can't say I chose the package name for that reason though!
And yes, I've installed
marginalia
as well. I'm still very new to all of this, though, so I'm sure there's plenty for me to learn before I can get things where I wanted.
There's a bit of a learning curve to move from monolithic solutions like ivy and helm to deliberately decomposed, but collaboratively developed, solutions like these.
It probably took me two weeks to "get it".
Many of the decisions here reflect now having understood it. My hope is the wiki can flourish as users start to experiment.
from citar.
Last question: would it help others, do you think, to move this to the discussion forum?
It's easy enough for me to do.
from citar.
from citar.
Related Issues (20)
- Feature request: Integration with Zotra HOT 3
- Custom `C-i` bindings do not play well with `citar-open` and `RET` HOT 9
- Feature request: `citar-open-files-or-links` HOT 4
- Customizable `citar-add-file-to-library` HOT 3
- Display transform function for full names HOT 15
- Alignment doesn't work with star in template HOT 1
- Misaligned completion suggestions with company mode HOT 2
- citar--format-candidates docstring confusion
- The Homepage button on melpa leads to a 404 HOT 5
- Installing citar with guix: "Symbol's value as variable is void: citar-indicator-create" HOT 7
- citeproc: add way to specify output format
- Citar fails to display files containing commas HOT 5
- Feature request: Allow `citar` to add multiple files to library item/citeky via `citar-add-file-to-library` HOT 1
- `citar-open-entry` receives wrong citekey HOT 6
- modularizing citar--select-multiple HOT 2
- citar functions to act on buffers HOT 6
- (How to?) add a direct call to `citar-file-open-external` from citar's "menu"
- Problems rendering superscripts correctly for in-text citations when exporting to ODT HOT 3
- Make citar-open more configurable HOT 9
- Issues with `citar-export-local-bib-file` HOT 8
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 citar.