|
8 | 8 | hooks: |
9 | 9 | - go mod tidy |
10 | 10 | - go mod download |
11 | | - - |
| 11 | + - go run github.com/google/wire/cmd/wire@latest |
| 12 | + - go run github.com/securego/gosec/v2/cmd/gosec@latest -quiet ./... |
| 13 | + - go run github.com/go-critic/go-critic/cmd/gocritic@latest check -enableAll ./... |
12 | 14 |
|
13 | 15 | builds: |
14 | 16 | - |
@@ -94,10 +96,34 @@ brews: |
94 | 96 | commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}" |
95 | 97 | folder: Formula |
96 | 98 | caveats: | |
97 | | - How to use this project. |
| 99 | + After install csv2api, run it with '-i' option to generate initial config.yml and data.csv files in the current dir: |
| 100 | + |
| 101 | + $ csv2api -i |
| 102 | + |
| 103 | + Prepare your config and input data files: |
| 104 | + |
| 105 | + In your config.yml: |
| 106 | + |
| 107 | + - Make sure that the first column name in the columns_order section is a primary key (PK) for your process. |
| 108 | + - Set up your API (base URL, token, endpoints, etc) in the api section. |
| 109 | + - Set up the filter for your fields in the filter_columns section. |
| 110 | + - Set up fields to be updated in the update_fields section. |
| 111 | + |
| 112 | + In your input data.csv: |
| 113 | + |
| 114 | + - Make sure that the first line of your CSV file contains the correct field names. |
| 115 | + |
| 116 | + 💡 Note: See the repository's Wiki page (https://github.com/koddr/csv2api/wiki) to understand the structure of the config and input data files. |
| 117 | + |
| 118 | + And now, run csv2api with options: |
| 119 | + |
| 120 | + $ csv2api -c /path/to/config.yml -d /path/to/data.csv -e CONFIG |
| 121 | + |
| 122 | + Done! Your transactions have been performed. |
98 | 123 | homepage: "https://github.com/koddr/{{ .ProjectName }}" |
99 | 124 | description: | |
100 | | - Description of my project. |
| 125 | + The csv2api parser reads the CSV file with the raw data, filters the records, identifies fields to be changed, and sends a request to update the data to the specified endpoint of your REST API. |
| 126 | + All actions take place according to the settings in the configuration file. |
101 | 127 | license: Apache 2.0 |
102 | 128 | skip_upload: false |
103 | 129 | # dependencies: |
@@ -127,7 +153,8 @@ nfpms: |
127 | 153 | - |
128 | 154 | maintainer: Vic Shóstak <[email protected]> |
129 | 155 | description: | |
130 | | - Description of my project. |
| 156 | + The csv2api parser reads the CSV file with the raw data, filters the records, identifies fields to be changed, and sends a request to update the data to the specified endpoint of your REST API. |
| 157 | + All actions take place according to the settings in the configuration file. |
131 | 158 | homepage: "https://github.com/koddr/{{ .ProjectName }}" |
132 | 159 | license: Apache 2.0 |
133 | 160 | formats: [ deb, rpm, apk, archlinux ] |
|
0 commit comments