Henrik Friedrichsen
09febf7187
cargo update + format + clippy
2020-11-21 15:42:17 +01:00
Bettehem
9baed7ae98
Added possibility to turn on/off shuffle using MPRIS ( #318 )
...
* Added possibility to turn shuffle on/off via MPRIS
* Simplified code to use unwrap_or instead of a match.
Changed the default value to be retrieved from spotify.
* only set shuffle setting if parameter was passed
* fix: fetch shuffle state with every MPRIS query
And not just once during DBus/MPRIS setup. Also, redraw UI when shuffle
state has changed.
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org >
2020-11-14 21:50:13 +01:00
Henrik Friedrichsen
5fb4eb7af2
fix: update playlist changes in local store
...
Move playlist change logic out of the library while we're at it and notify
the library of changes instead.
fixes #302
2020-10-25 00:09:23 +02:00
dependabot-preview[bot]
e698d51e59
Bump dbus from 0.8.4 to 0.9.0 ( #296 )
...
* Bump dbus from 0.8.4 to 0.9.0
Bumps [dbus](https://github.com/diwic/dbus-rs ) from 0.8.4 to 0.9.0.
- [Release notes](https://github.com/diwic/dbus-rs/releases )
- [Commits](https://github.com/diwic/dbus-rs/compare/dbus-v0.8.4...dbus-v0.9.0 )
Signed-off-by: dependabot-preview[bot] <support@dependabot.com >
* migrate to dbus/dbus-tree 0.9.0
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org >
2020-10-24 00:03:19 +02:00
Henrik Friedrichsen
013beb245b
refactor: pass globally mutable config reference
...
Before, copies of the configuration were passed over. This change also
causes configuration reloads to affect the entire application and is
easier to maintain but introduces some RwLock overhead.
2020-10-18 13:09:45 +02:00
Mario Rodas
6bb2c08705
Replace directories with platform_dirs create
...
`directories` create is no longer maintained, and uses
`~/Library/Preferences` on MacOS, but Apple advises against creating
files in `Preferences`.
`platform-dirs` allows to use `~/.config` on MacOS.
2020-10-12 10:46:36 +02:00
Henrik Friedrichsen
f3c66111a2
cargo clippy
2020-10-10 20:47:12 +02:00
Bolli
79093eca1e
feat: add insert command to paste spotify links ( #277 )
...
* feat: add insert command to paste spotify links
- use Ctrl-v to paste from clipboard or use :insert without an argument
* fix: handle paste on disabled clipboard feature
* fix: handle wrong URIs
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org >
2020-10-09 19:26:52 +02:00
Moshe Sherman
f2b4f01242
Vim like search ( #279 )
...
* add quick search within a list
* vim like search navigation
* close cmd line with esc
* format
* document changes in README
2020-10-05 13:50:12 +02:00
pin
b5e718f5f6
Use libc for setlocale() to fix non-ASCII ( #256 )
...
* Use libc for setlocale() to fix non-ASCII
character printing.
https://github.com/hrkfdn/ncspot/issues/221
* move string instantiation outside unsafe block
update libc crate while at it
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org >
2020-08-29 11:27:47 +02:00
Henrik Friedrichsen
1edf28a165
make contextmenu aware of commands
...
e.g. to process vim-like keybindings for navigation
fixes #108 , fixes #157 , fixes #178 , fixes #199 , fixes #250
2020-08-23 20:44:03 +02:00
Henrik Friedrichsen
e5bc12b1ba
use cfg of spotify object
...
TODO:
- apply this to other single config values that are passed directly, e.g. in the
statusbar
- use a more appropriate object to hold `cfg`
2020-08-18 23:06:41 +02:00
Ronak Buch
097f59eb83
Add notifications
2020-08-18 23:06:38 +02:00
Henrik Friedrichsen
4f71b2489b
implement command to reload config ( #243 )
...
* implement command to reload themes
* refresh keybindings after config reload
2020-08-12 01:12:08 +02:00
Henrik Friedrichsen
1b1d392ab8
podcast support ( #203 )
...
* implement search for shows/podcasts
* create Playable supertype for queue to contain tracks and episodes
* wip: implement playback of episodes
* load spotify id from uri instead of raw id to fix podcast playback
* show duration for podcast episodes
* implement generic status bar for playables (tracks and episodes)
omit saved indicator for now as the library does not yet support podcasts
* instead of only the last 50 fetch all episodes of a show
* refactor: extract Playable code to separate file
* implement playback/queuing of shows + sharing url
* implement podcast library
* migrate mpris code to Playable supertype
2020-07-14 10:38:22 +02:00
Henrik Friedrichsen
8188f9e304
fix: only clear credentials when they're invalid
...
fixes #77
2020-06-21 21:50:49 +02:00
Henrik Friedrichsen
65126c5c78
add configuration value to drop default keybindings
...
resolves #204
2020-06-18 19:33:46 +02:00
Henrik Friedrichsen
8013609d0e
recreate librespot session when it's invalid
...
initial attempt to handle #192
2020-06-13 20:23:28 +02:00
Henrik Friedrichsen
ce5b11dac4
update to cursive 0.15.0
2020-06-02 23:19:21 +02:00
Henrik Friedrichsen
91ce808ef8
support configuration of audio backend and backend device
...
fixes #194
2020-05-19 00:05:32 +02:00
Henrik Friedrichsen
b5566351b5
use cached credentials from librespot
...
attempt at fixing #160
2020-04-08 21:07:20 +02:00
Henrik Friedrichsen
1b0ac4d5cc
migrate to futures 0.3
2020-03-28 23:31:27 +01:00
Henrik Friedrichsen
082675a5d7
push help view to stack instead of making it a separate screen
...
fixes #157
2020-03-21 15:51:35 +01:00
Henrik Friedrichsen
dccb36d8e7
update to rust edition 2018 + bump version
2020-03-15 11:06:24 +01:00
dann-merlin
56a178dcfd
Added configuration option for initial shuffle, repeat, volume
2020-03-03 18:05:03 +01:00
Henrik Friedrichsen
d2915316da
various non-functional code cleanups
2020-02-21 23:33:08 +01:00
Henrik Friedrichsen
54230bd85b
show commands in help screen in the same syntax they are parsed
2020-02-05 22:48:35 +01:00
Henrik Friedrichsen
cea2cbb33e
remove unused cfg parameters
2020-02-05 22:08:11 +01:00
Henrik Friedrichsen
fa960a4eba
add initial help screen + keybinding -> command parsing
...
still needs some more work, i.e. to show commands in help instead of parsed data
structures, but it's a start.
fixes #117
fixes #121
2020-02-02 21:51:40 +01:00
Henrik Friedrichsen
bf2a72ad81
expose keybindings in CommandManager for help view
2020-02-02 20:38:55 +01:00
Henrik Friedrichsen
8924b85390
fix deprecation warnings that occured due to cursive 0.14.0 upgrade
2020-02-02 20:10:21 +01:00
Henrik Friedrichsen
e8f8b25de7
get version during compile time from cargo metadata
2019-11-30 17:39:34 +01:00
Henrik Friedrichsen
0695434ca0
fix: recursively create directories instead of failing
...
e.g. when ~/.config does not exist
2019-11-24 16:39:15 +01:00
Henrik Friedrichsen
e697b97d8c
major dependency cleanup
...
- depend on specific librespot crates to remove clutter
- update versions
this should also help building on openbsd, as the unused librespot-connect
depended on the nix crate, which does not build on openbsd.
2019-11-24 16:38:15 +01:00
Henrik Friedrichsen
177c4893e0
add proxy configuration value
...
+ document possible configuration options
fixes #109
2019-11-21 22:45:09 +01:00
Henrik Friedrichsen
cd80ace4a8
remove debug log spamming + log player events
2019-09-01 01:10:19 +02:00
Henrik Friedrichsen
f7458b4137
make sharing to clipboard a feature that can be disabled
...
this is for users that want to eliminate dependences (e.g. libxcb).
the feature is enabled by default and must be explicitly disabled.
fixes #84
2019-08-13 11:49:27 +02:00
Rasmus Larsen
db7a09c87b
Command parser
2019-05-21 18:11:54 +02:00
Rasmus Larsen
5500b34887
Remove dead code
2019-05-21 16:34:50 +02:00
Rasmus Larsen
1e0d9ea952
Handle default command behavior
2019-05-21 16:01:56 +02:00
Rasmus Larsen
1671db14c1
Move to enum-based commands
2019-05-20 22:15:12 +02:00
Henrik Friedrichsen
4b4a027c3c
add basepath cmdline flag
...
this allows a basepath to be set via commandline where ncspot will place
configuration and cache files.
fixes #65
2019-05-16 23:58:05 +02:00
Rasmus Larsen
de1dea5c68
Add a keybind and shortcut to share the currently playing song
2019-05-07 23:39:15 +02:00
KoffeinFlummi
a98a4645f6
Make library the default view
2019-04-28 11:56:59 +02:00
KoffeinFlummi
82dee638c5
Display saved status in statusbar
2019-04-28 11:04:59 +02:00
KoffeinFlummi
1a17860957
cargo fmt
2019-04-20 00:11:43 +02:00
KoffeinFlummi
adba809327
Display saved/followed checkmark
2019-04-18 14:04:40 +02:00
KoffeinFlummi
210c7d9f4e
Implement saved tracks, albums, and artists
2019-04-16 19:52:22 +02:00
Henrik Friedrichsen
0bbba3c57d
remove clippy from CI for now, as it's too strict
2019-04-15 22:07:54 +02:00
Henrik Friedrichsen
8738472e87
test login credentials before entering main program
...
closes #58
this is a bit messy, as librespot panics, when authentication fails. thus, we
test the credentials in a separate thread to handle the panic.
see also: https://github.com/librespot-org/librespot/issues/108
2019-04-15 21:59:19 +02:00