Commit graph

65 commits

Author SHA1 Message Date
LoricAndre 7df8b77739
feat: use clap & derive for options, manpage & completions (#586)
Some checks failed
Build & Test / test (linux, ubuntu-latest, stable, x86_64-unknown-linux-musl) (push) Has been cancelled
Build & Test / test (macos, macos-latest, stable, x86_64-apple-darwin) (push) Has been cancelled
Build & Test / clippy (linux, ubuntu-latest, stable, x86_64-unknown-linux-musl) (push) Has been cancelled
Build & Test / clippy (macos, macos-latest, stable, x86_64-apple-darwin) (push) Has been cancelled
Build & Test / rustfmt (push) Has been cancelled
* feat: use clap & derive for options, manpage & completions

* clippy & fmt

* fix: correctly handle errors

* fix: disable doctest

* fix: readd replstr

* fix: reserve --tmux until it is implemented

* explicit panic messages for history files

* fix after merge

---------

Co-authored-by: LoricAndre <loric.andre@pm.me>
2024-11-20 17:01:08 +01:00
otto-dev 064b7b78e2
Return items of multi-select in order of selection (#468)
Some checks are pending
Build & Test / test (linux, ubuntu-latest, stable, x86_64-unknown-linux-musl) (push) Waiting to run
Build & Test / test (macos, macos-latest, stable, x86_64-apple-darwin) (push) Waiting to run
Build & Test / clippy (linux, ubuntu-latest, stable, x86_64-unknown-linux-musl) (push) Waiting to run
Build & Test / clippy (macos, macos-latest, stable, x86_64-apple-darwin) (push) Waiting to run
Build & Test / rustfmt (push) Waiting to run
* Return items of multi-select in order of selection

* chore: update deps and fix lots of clippy lints

* cargo update

* Fix more lints + ci

* Include repology reference

`skim` is packaged in more then the listed repositories. By referring to repology everyone can easily check whether their package manager of choice has it. Also the list at repology auto updates and includes the information which versions are packaged.

* Add light colors parsing support

* Update ci.yml

* Update ci.yml

* Make bin only deps set optional

* transparency on start

* release notes

* bump

* bump to 0.10.1

* fix: print version from Cargo.toml with latest clap

Upgrading to clap 3 has changed some behavior in clap, as the
version option is automatically populated. This means the custom
code has never been executed.

Lets fix this by using the clap built in functionality to automatically
use the crate version in the builtin version option.

This fixes commit 7d922a02a0

Signed-off-by: Levente Polyak <levente@leventepolyak.net>

* bump version

* update defer-drop to v1.3.0

* Update Cargo.toml

* bump

* Update README.md

* bump

* doc(discord): discord invitation link

* README.md: "Package Managers": add Portage

* document display issue + fix

* Update sk.1

* Update sk-tmux.1

* remove -K and -R flags from tmux popup: uknown flags (#551)

Co-authored-by: ymnejmi <ymnejmi@github.com>

* chore: fix clippy

* Create dependabot.yml

* Bump log from 0.4.17 to 0.4.22 (#581)

Bumps [log](https://github.com/rust-lang/log) from 0.4.17 to 0.4.22.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.17...0.4.22)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump vte from 0.11.0 to 0.13.0 (#582)

Bumps [vte](https://github.com/alacritty/vte) from 0.11.0 to 0.13.0.
- [Release notes](https://github.com/alacritty/vte/releases)
- [Changelog](https://github.com/alacritty/vte/blob/master/CHANGELOG.md)
- [Commits](https://github.com/alacritty/vte/compare/v0.11.0...v0.13.0)

---
updated-dependencies:
- dependency-name: vte
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump derive_builder from 0.11.2 to 0.20.2 (#583)

Bumps [derive_builder](https://github.com/colin-kiegel/rust-derive-builder) from 0.11.2 to 0.20.2.
- [Release notes](https://github.com/colin-kiegel/rust-derive-builder/releases)
- [Commits](https://github.com/colin-kiegel/rust-derive-builder/compare/v0.11.2...v0.20.2)

---
updated-dependencies:
- dependency-name: derive_builder
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* bootstrap contributing.md

* Bump shlex from 1.1.0 to 1.3.0 (#556)

Bumps [shlex](https://github.com/comex/rust-shlex) from 1.1.0 to 1.3.0.
- [Changelog](https://github.com/comex/rust-shlex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/comex/rust-shlex/commits)

---
updated-dependencies:
- dependency-name: shlex
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Cargo: remove unuseful entries (#382)

* feat: use IndexMap to order selected items

* test: add e2e

* update lock after rebase

* prepare merge

* update lock

* clippy

* Delete test.Dockerfile

* fix lockfile

* fix dep version regressions

---------

Signed-off-by: Levente Polyak <levente@leventepolyak.net>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: grant0417 <grant@ggurvis.com>
Co-authored-by: grant0417 <grantgurvis@gmail.com>
Co-authored-by: Merlin <megoettlinger@gmail.com>
Co-authored-by: TD-Sky <three-dim-sky@foxmail.com>
Co-authored-by: Grant G <grant0417@users.noreply.github.com>
Co-authored-by: EdenEast <edenofest@gmail.com>
Co-authored-by: yazgoo <yazgoo@gmail.com>
Co-authored-by: Levente Polyak <levente@leventepolyak.net>
Co-authored-by: onatm <onat.mercan@truelayer.com>
Co-authored-by: yazgoo <yazgoo@users.noreply.github.com>
Co-authored-by: Vitaly Zdanevich <zdanevich.vitaly@ya.ru>
Co-authored-by: sisrfeng <53520949+sisrfeng@users.noreply.github.com>
Co-authored-by: ymnejmi <134085326+ymnejmi@users.noreply.github.com>
Co-authored-by: ymnejmi <ymnejmi@github.com>
Co-authored-by: LoricAndre <loric.andre@pm.me>
Co-authored-by: LoricAndre <57358788+LoricAndre@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Marco Ieni <11428655+MarcoIeni@users.noreply.github.com>
2024-11-18 22:16:23 +01:00
paul 363efdd725 Fix test 2021-11-20 16:12:40 +03:00
Jinzhou Zhang c49fb847e2 fix tests on MacOS 2021-02-15 18:26:17 +08:00
Jinzhou Zhang f253e3ed00 fix tests on MacOS 2021-02-15 18:15:27 +08:00
Jinzhou Zhang b6c387ab09 [ci] use github actions 2021-02-15 16:04:44 +08:00
Jinzhou Zhang 1cf8e4c8d6 fix #365: new option --show-cmd-error
Currently the invoked command would fail silently. Sometimes this might
not be desirable because we have no idea whether it outputs nothing or
died.

New option `--show-cmd-error` is designed to send the error message and
display them as items.

It's somehow a trade-off choice that I don't want to modify the
current library interface. Also it's not made default because there
might be several fail invocation before we complete the whole
"cmd-query".
2020-10-24 21:30:49 +08:00
Jinzhou Zhang 60c73d3c4a fix #361: support liberal space by \ 2020-10-22 21:12:29 +08:00
Jinzhou Zhang d995b852b0 fix #359: panic with multi-byte and regex 2020-10-21 22:24:29 +08:00
Jinzhou Zhang ab15f67a37 feature: support initial scroll for preview window 2020-10-20 15:00:23 +08:00
Jinzhou Zhang 9368bb00b7 fix #328: --no-clear-if-empty to preserve selection 2020-10-18 11:18:35 +08:00
Jinzhou Zhang 03b3e08f6c fix #309: support pre-selection
- pre-select-n: select first `n` items
- pre-select-pat: select items that matches regex
- pre-select-items: select items from a preset
- pre-select-file: select items from a preset that's loaded from file
2020-10-17 17:53:55 +08:00
Jinzhou Zhang d0f46b671e fix: multiple selection (regression in 1d72fca) 2020-10-17 10:10:15 +08:00
Jinzhou Zhang f1a898abe6 feature: support skip-to-pattern 2020-10-14 21:59:03 +08:00
Jinzhou Zhang 5081fe369e support negative horizontal scroll 2020-10-14 21:27:03 +08:00
Jinzhou Zhang c462ca136a add tests for key bindings in interactive mode 2020-10-04 10:30:12 +08:00
blindingdark 4479c52f4b [test] add more test for case print0 2020-03-03 05:24:28 +08:00
Jinzhou Zhang 2d2b56c4c2 Fix #278: NUL not working in preview cmd
Now NUL will be translated back to `\0` when invoking execute or preview
command.

It may not be expected in all cases, but it is the best we can do for
now.
2020-03-01 16:51:05 +08:00
Jinzhou Zhang 2fcf813c89 fix tests for [cmd]query history functions 2020-03-01 13:54:07 +08:00
Jinzhou Zhang 62b6b2feb0 Fix #276: add new action if-non-matched
- the action will be executed if the current matched item is `0`
- Note that even if the reader or matched is not completed yet, the
  action would still be executed if the current matched item is `0`
2020-03-01 12:44:11 +08:00
Jinzhou Zhang e028df98cb Fix #276: execute panic on zero results
- If the command refers to items, it is forbidden on zero results
- otherwise the command is allowed to execute all the time
2020-03-01 12:18:08 +08:00
Jinzhou Zhang f8332130b3 Fix #273: add spinner for inline-info mode 2020-02-28 09:45:08 +08:00
Jinzhou Zhang d956d3c020 Fix #63: history for query and command query
Via option `--history` and `--cmd-history`
2020-02-25 13:23:31 +08:00
Jinzhou Zhang 9a826ef388 fix tests of case folding on Linux 2020-02-23 20:44:26 +08:00
Jinzhou Zhang 3edc75d75e add tests for case folding 2020-02-23 18:45:11 +08:00
Jinzhou Zhang 9d813aa474 update cases on behavior change of multi-selection 2020-02-02 14:20:56 +08:00
Jinzhou Zhang d06c3cdf30
Merge pull request #151 from lotabout/fix-test
[test] fix tests
2019-03-24 23:13:09 +08:00
Jinzhou Zhang 4b70b1a1b4 [test] fix tests
tests will wait till skim is ready. It relied on the item count or
matcher count which doesn't reflect the actual status. So I add an
additional status (.) at the end indicating matcher is done.
2019-03-24 22:28:43 +08:00
Jinzhou Zhang f5c72d212d [test] fix test for filter mode 2019-03-24 00:07:04 +08:00
Jinzhou Zhang dc83de4d13 fix #142: NULL character dropped with --ansi
after 0.6.0, vte was used for parsing ANSI codes, \0, \n, \t are
treated specially. Forgot to pick out \0.
2019-03-20 09:20:31 +08:00
Jinzhou Zhang 15abca977c [test] --header-lines 2019-03-19 11:51:05 +08:00
Jinzhou Zhang 4b4b7d5453 [inline-info] fix test 2019-03-17 14:15:40 +08:00
Jinzhou Zhang afaae87f04 [test] wait a little bit after send keys 2019-02-24 22:02:53 +08:00
Jinzhou Zhang 4652336040 [test] wait for commands to finish 2019-02-24 16:25:30 +08:00
Jinzhou Zhang e8e4b7cc88 fix tests 2019-02-24 14:19:46 +08:00
Jinzhou Zhang e72d3ce9ad [test] add test for --nth 2019-02-23 09:46:26 +08:00
Jinzhou Zhang 4e577feef2 fix #131 --with-nth was broken 2019-02-23 09:33:36 +08:00
Stephane Fontaine 93d4df9157 [tests] refactor trivial tests
Add test for --header option
2018-11-10 11:19:53 +04:00
Stephane Fontaine 3a883b1e98 [tests] redirect stderr to devnull (needs py 3.3) 2018-11-10 11:19:53 +04:00
Stephane Fontaine b5f21c947c Add test for inline infos 2018-11-10 11:19:53 +04:00
Stephane Fontaine 9da25cbb69 [tests] fix read0 test 2018-11-10 11:19:16 +04:00
Stephane Fontaine bd625d39cc [tests] rely on python to quote arguments 2018-11-10 11:19:16 +04:00
Jinzhou Zhang c66eba0691
Merge pull request #102 from Lompik/fieldnumber
Consistent --nth and --with-nth numbering
2018-11-05 22:27:35 +08:00
Stephane Fontaine 44e8e2c524 [test] Add test case for with-nth & preview transform fields 2018-11-05 09:59:07 +04:00
Stephane Fontaine 34d795ff4b squash! Add inline-info test case 2018-11-04 11:01:13 +04:00
Stephane Fontaine 2413cbcce8 Revert "less fancy inline info test"
This reverts commit 56b7cd1b8d.
2018-11-04 10:57:40 +04:00
Stephane Fontaine 56b7cd1b8d less fancy inline info test 2018-11-04 10:39:02 +04:00
Stephane Fontaine 81b3d7ede2 Try fix travis/darwin 2018-11-04 10:09:33 +04:00
Stephane Fontaine 120a3ca61d Add inline-info test case 2018-11-04 09:39:41 +04:00
Jinzhou Zhang c82c7956ba [ci] fix tests 2018-10-01 12:16:55 +08:00