Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This tiny program prints full path of the toplevel git / syncthing directory
you're in, or exits(1) if you're not inside one.

Usage: `uproot git` or `uproot st`.

Note: this program was called `gitroot` before and was limited to git only,
thus it's providing a oneliner `gitroot` script for compatibility.


What else...
It is intended to be run thousands of times within various scripts,
thus the C version, consuming the least amount of resources possible.

By the way, invoking 'uproot git' is a shorter and quicker equivalent
of running the following vanilla git subcommand:

`git rev-parse --show-toplevel`

(vanilla syncthing does not have an equivalent).


Licensed under FreeBSD 3-clause license.

About

tiny C prog to find the toplevel git or syncthing dir you're in

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages