Comments (9)
Hi @brainlessdeveloper thanks for the interest in bitwarden-rofi!
I can understand why you'd want to limit the amount of lines shown, so that's a go for sure.
You could try and send all the options bwmenu does not know to rofi. This way we won't have to add new rofi flags to bwmenu every time.. What's your take on this?
# example
bwmenu -c 5 -lines 2
# above would show a notification for 5 seconds and call rofi with args '-lines 2'
from bitwarden-rofi.
Exactly, my suggestion was to have bwmenu
extend the arguments rofi accepts by just passing them over just like you mentioned.
from bitwarden-rofi.
And of course to avoid needing to implement extra stuff on bwmenu
, apart from the option fall-through.
from bitwarden-rofi.
I'd be interested in a patch like this 😁
from bitwarden-rofi.
I'll take a look at it during the weekend :) I'm quite busy nowadays.
Thanks for the tool btw!
from bitwarden-rofi.
Another common convention is --
.
bwmenu [OPTIONS] -- [ROFI_OPTIONS]
Example:
bwmenu --seconds 10 -- -lines 2
I think this is a working implementation of that:
rofi_menu() {
rofi -dmenu -p 'Name' \
-i -no-custom \
-mesg ' <b>Alt+r</b>: sync | <b>Alt+u</b>: urls | <b>Alt+n</b>: names | <b>Alt+c</b>: folders' \
-kb-custom-1 alt+r \
-kb-custom-2 alt+n \
-kb-custom-3 alt+u \
-kb-custom-4 alt+c \
"$@"
}
from bitwarden-rofi.
I think this is indeed the correct way to do this.
from bitwarden-rofi.
yarn
used to follow that convention:
yarn my-script-from-package-json -yarn-arg-1 -yarn-arg-2 -- -arg-for-my-script
They later switched to the same thing but without the --
. I like the --
version too, anyway.
from bitwarden-rofi.
Another common convention is
--
.bwmenu [OPTIONS] -- [ROFI_OPTIONS]
Example:
bwmenu --seconds 10 -- -lines 2
I think this is a working implementation of that:
rofi_menu() { rofi -dmenu -p 'Name' \ -i -no-custom \ -mesg ' <b>Alt+r</b>: sync | <b>Alt+u</b>: urls | <b>Alt+n</b>: names | <b>Alt+c</b>: folders' \ -kb-custom-1 alt+r \ -kb-custom-2 alt+n \ -kb-custom-3 alt+u \ -kb-custom-4 alt+c \ "$@" }
I tried your implementation and apparently it gets passed over character by character:
getopt: invalid option -- 'l'
getopt: invalid option -- 'i'
getopt: invalid option -- 'n'
getopt: invalid option -- 'e'
getopt: invalid option -- 's'
I don't know how to use getopt
to do this though.
from bitwarden-rofi.
Related Issues (20)
- Feature request: Automatic login HOT 2
- Increasing Loadspeed HOT 2
- notification showing html brackets HOT 1
- Workaround for error "Could not load items" HOT 5
- Switch between name and dirs closes the app HOT 1
- Totp not showing up HOT 1
- Race condition between xdotool and user's finger when autotyping HOT 1
- I can't change the theme HOT 1
- Error and master password prompt dont respect passed arguments HOT 2
- rofi 1.7.0 moved width and lines from config to Theme HOT 1
- Rofi's command-line options changed
- Changing keybinding HOT 2
- Add support for user-defined autotype tool
- autofill fill all account of the same domain
- Update AUR packages HOT 1
- Focus last active i3 window HOT 2
- Could not load items - mac failed HOT 2
- Not able to unlock session HOT 3
- "Could not load items:" HOT 3
- Could not load items error HOT 9
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 bitwarden-rofi.