Comments (4)
If the command isn't supported by git out of the box, you need to set it up in your config using man.tdr.cmd
:
https://git-scm.com/docs/git-help#_man_viewer
However, tealdeer is not a generic man viewer, so I'm not sure if this is the best idea 🙂 However, if it works for you, that's great.
I'll close this issue for now since it's not a feature request, but feel free to add further comments.
from tealdeer.
Git does not use your shell to spawn the man
process, so it is unaware of your aliases. You need to tell git by following the explanation from the link you provided. If setting the configuration does not work, you could try setting the environment variable GIT_MAN_VIEWER=tldr
before running git, probably in your shell config. Does this help?
from tealdeer.
No, that does not seem to work either:
$ export GIT_MAN_VIEWER=tldr
$ echo $GIT_MAN_VIEWER
tldr
$ git log --help
warning: 'tldr': unknown man viewer.
warning: failed to exec 'man': No such file or directory
fatal: no man viewer handled the request
from tealdeer.
That works,
$ git config --global man.viewer tldr
$ git config --global man.tldr.cmd tldr
$ git log --help
Show a history of commits.
More information: <https://git-scm.com/docs/git-log>.
Show the sequence of commits starting from the current one, in reverse chronological order of the Git repository in the current working directory:
git log
Show the history of a particular file or directory, including differences:
git log -p path/to/file_or_directory
Show an overview of which file(s) changed in each commit:
git log --stat
Show a graph of commits in the current branch using only the first line of each commit message:
git log --oneline --graph
Show a graph of all commits, tags and branches in the entire repo:
git log --oneline --decorate --all --graph
Show only commits whose messages include a given string (case-insensitively):
git log -i --grep search_string
Show the last N commits from a certain author:
git log -n number --author=author
Show commits between two dates (yyyy-mm-dd):
git log --before="2017-01-29" --after="2017-01-17"
Thanks!
from tealdeer.
Related Issues (20)
- Respect XDG_* variables on macos if set HOT 13
- updating `$TEALDEER_CACHE_DIR` not recognized on macos HOT 3
- how to render `{{` and `}}`? HOT 2
- Custom Pages With `.md` Extension HOT 13
- unncessary breaking change with --markdown flag HOT 9
- Allow passing `common` as platform
- Create an auto man page HOT 1
- Unit test failed on Windows HOT 3
- opensuse (tealdeer) can't find cache after updating HOT 9
- Can't update cache: invalid peer certificate contents: invalid peer certificate: UnknownIssuer HOT 15
- Include shell completion in crates.io releases? HOT 1
- Better/More detailed --list HOT 5
- Add a language option when updating the cache HOT 13
- Help getting custom pages to work HOT 4
- tldr -u take long time to succeed HOT 1
- Add a random flag like node client HOT 4
- How to migrate from TEALDEER_CACHE_DIR to config file HOT 1
- Support Client Specification 2.1 and 2.2 HOT 1
- Support for clap version 4 HOT 2
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 tealdeer.