Skip to content
This repository has been archived by the owner on May 24, 2024. It is now read-only.

Commit

Permalink
Merge pull request #11 from tech-greedy/xinaxu/rename
Browse files Browse the repository at this point in the history
Rename go-generate-car to generate-car
  • Loading branch information
xinaxu authored Feb 28, 2023
2 parents ffb7f9e + 6809d76 commit d713f43
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
16 changes: 11 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
# go-generate-car
# generate-car
A simple CLI to generate car file and compute commp at the same time.

[![Pull Request](https://github.com/tech-greedy/go-generate-car/actions/workflows/pull-request.yml/badge.svg)](https://github.com/tech-greedy/go-generate-car/actions/workflows/pull-request.yml)
[![Pull Request](https://github.com/tech-greedy/generate-car/actions/workflows/pull-request.yml/badge.svg)](https://github.com/tech-greedy/generate-car/actions/workflows/pull-request.yml)

### Installation
```shell
$ ./generate-car -h
$ go install github.com/tech-greedy/generate-car
```

### Usage
```shell
$ generate-car -h
NAME:
generate-car - generate car archive from list of files and compute commp in the mean time

Expand All @@ -27,9 +33,9 @@ GLOBAL OPTIONS:
When `--single` is specified, the input is a single file or folder to be included in full, instead of a spec JSON.
```shell
# Generate car file from a single file
$ ./generate-car --single -i test_path/test_file. -o out_dir -p test_path
$ generate-car --single -i test_path/test_file. -o out_dir -p test_path
# Generate car file from a single folder
$ ./generate-car --single -i test_path/test_folder -o out_dir -p test_path
$ generate-car --single -i test_path/test_folder -o out_dir -p test_path
```

For advanced user, without specifying `--single` the input file needs to be a json file that contains a list of file information SORTED by the path. This is useful if you only want to include specific files within a directory or only part of a large file. i.e.
Expand Down
2 changes: 1 addition & 1 deletion generate-car.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"github.com/google/uuid"
"github.com/ipfs/go-cid"
cbor "github.com/ipfs/go-ipld-cbor"
"github.com/tech-greedy/go-generate-car/util"
"github.com/tech-greedy/generate-car/util"
"github.com/urfave/cli/v2"
)

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/tech-greedy/go-generate-car
module github.com/tech-greedy/generate-car

go 1.17

Expand Down

0 comments on commit d713f43

Please sign in to comment.