From 716dc5382cd6210e1657ad3d2127f91da1ed6cc7 Mon Sep 17 00:00:00 2001 From: mike-ward Date: Wed, 19 Jun 2024 18:44:06 -0500 Subject: [PATCH] add make file --- .gitignore | 1 + Makefile | 4 ++++ README.md | 8 +++----- lsv/args.v | 4 ++-- 4 files changed, 10 insertions(+), 7 deletions(-) create mode 100644 Makefile diff --git a/.gitignore b/.gitignore index 02f9f43..d7f397b 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ */lsv +bin diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..b98888e --- /dev/null +++ b/Makefile @@ -0,0 +1,4 @@ +.PHONY: all + +all: + @v -prod lsv -o bin/lsv diff --git a/README.md b/README.md index bbbc5cd..606795d 100644 --- a/README.md +++ b/README.md @@ -22,11 +22,9 @@ Build `lsv` from source. I plan to have binary releases after beta. - [Install the V compiler](https://docs.vlang.io/installing-v-from-source.html). It takes a minute or less - `git clone https://github.com/mike-ward/lsv.git` -- `cd lsv/lsv` -- `v .` or `v -prod .` for an optimized version -- `./lsv` - -and your done. No kidding, that's it. +- `cd lsv` +- `make` +- `bin/lsv` ## Help ``` diff --git a/lsv/args.v b/lsv/args.v index 9b56996..50fb475 100644 --- a/lsv/args.v +++ b/lsv/args.v @@ -72,7 +72,7 @@ fn parse_args(args []string) Args { mut fp := flag.new_flag_parser(args) fp.application(app_name) - fp.version('2024.1.beta') + fp.version('2024.1.beta.1') fp.skip_executable() fp.description('List information about FILES') fp.arguments_description('[FILES]') @@ -124,7 +124,7 @@ fn parse_args(args []string) Args { fp.footer(' The -c option emits color codes when standard output is - connected to a terminal. Colors are defined in the LS_COLORS + connected to a terminal. Colors are defined in the LS_COLORS environment variable.'.trim_indent()) files := fp.finalize() or { exit_error(err.msg()) }