mirror of
https://github.com/dchakro/brewlog.git
synced 2026-05-17 10:12:16 -07:00
update files
This commit is contained in:
parent
b9216cebbc
commit
7228492a12
3 changed files with 16 additions and 11 deletions
|
|
@ -21,7 +21,7 @@ Now you'll be easily able to track the changes made by `brew upgrade`or `brew cl
|
|||
### How to use
|
||||
|
||||
```sh
|
||||
curl -sSL 'install.sh' | bash
|
||||
curl -sSL 'https://raw.githubusercontent.com/robocopAlpha/brewlog/master/install.sh' | bash
|
||||
|
||||
# Show help
|
||||
brewlog --help
|
||||
|
|
|
|||
23
brewlog.sh
23
brewlog.sh
|
|
@ -21,14 +21,13 @@ Usage:
|
|||
brewlog [brew command] [arguments to homebrew]
|
||||
e.g.
|
||||
brewlog install ffmpeg, invokes "brew install ffmpeg" and writes output to a log file.
|
||||
|
||||
--help Show help
|
||||
--brew-help show brew commands (alias to "brew help")
|
||||
|
||||
OPTIONS:
|
||||
version Show brewlog version
|
||||
archive Archives the current log file as .xz
|
||||
tail [-n INT] Show the last "INT" lines from the log file.
|
||||
|
||||
OPTIONS:
|
||||
--help Show help
|
||||
--brew-help Show brew commands (alias to "brew help")
|
||||
version Show brewlog version info
|
||||
archive Archives the current log file as .xz
|
||||
tail [-n INT] Show the last "INT" lines from the log file.
|
||||
(default: last 15 lines)
|
||||
|
||||
Homebrew/Linuxbrew Function examples:
|
||||
|
|
@ -52,7 +51,6 @@ Follow the development: https://github.com/robocopAlpha/brewlog
|
|||
|
||||
';
|
||||
}
|
||||
VERSION
|
||||
|
||||
if [ ! -f "$LOGFILE" ] ; then
|
||||
# Creating brew.log
|
||||
|
|
@ -60,11 +58,16 @@ if [ ! -f "$LOGFILE" ] ; then
|
|||
mkdir -p "$(dirname "$LOGFILE")"
|
||||
touch "$LOGFILE"
|
||||
fi
|
||||
|
||||
if [ $# -eq 0 ]; then
|
||||
HELP
|
||||
fi
|
||||
|
||||
if [ "$1" == "--help" ]; then
|
||||
HELP
|
||||
elif [ "$1" == "--brew-help" ]; then
|
||||
brew help
|
||||
elif [ "$1" == "--brew-help" ]; then
|
||||
elif [ "$1" == "version" ]; then
|
||||
VERSION
|
||||
elif [ "$1" == "tail" ]; then
|
||||
if [ "$2" == "-n" ]; then
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [ -w /usr/local/bin ]; then
|
||||
curl -sSL 'https://raw.githubusercontent.com/robocopAlpha/brewlog/master/brewlog.sh' > /usr/local/bin/brewlog
|
||||
chmod +x /usr/local/bin/brewlog
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue