Skip to content

Commit 0499514

Browse files
committed
tweaks
1 parent 66aa088 commit 0499514

File tree

3 files changed

+75
-49
lines changed

3 files changed

+75
-49
lines changed

.github/dependabot.yml

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,33 @@ updates:
77
- package-ecosystem: "gomod"
88
directory: "/"
99
schedule:
10-
interval: "monthly"
10+
interval: "weekly"
11+
day: "monday"
12+
time: "09:00"
13+
timezone: "UTC"
14+
open-pull-requests-limit: 10
1115
groups:
12-
updates:
16+
security-updates:
17+
applies-to: security-updates
18+
update-types:
19+
- "patch"
20+
minor-updates:
1321
update-types:
1422
- "minor"
23+
patch-updates:
24+
update-types:
1525
- "patch"
26+
ignore:
27+
- dependency-name: "golang.org/x/*"
28+
versions: [">= 2.0.0"]
1629
- package-ecosystem: github-actions
1730
directory: "/"
1831
schedule:
19-
interval: monthly
32+
interval: weekly
33+
day: "monday"
34+
time: "09:00"
35+
timezone: "UTC"
36+
open-pull-requests-limit: 5
37+
ignore:
38+
- dependency-name: "*"
39+
update-types: ["version-update:semver-major"]

.github/workflows/go.yml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,26 +8,22 @@ on:
88
workflow_dispatch:
99
jobs:
1010
build:
11-
runs-on: ${{ matrix.os }}
12-
strategy:
13-
matrix:
14-
os: [ubuntu-latest, windows-latest]
15-
go: [1.25]
11+
runs-on: ubuntu-latest
1612
steps:
1713
- uses: actions/checkout@v6
1814
- name: Set up Go
1915
uses: actions/setup-go@v6
2016
with:
21-
go-version: ${{ matrix.go }}
17+
go-version: '1.25.7'
18+
cache: true
2219
- name: Build
2320
run: go install
2421
- name: Test
2522
run: |
2623
go test -v -cover ./... -coverprofile coverage.out -coverpkg ./...
27-
go tool cover -func coverage.out -o coverage.out # Replaces coverage.out with the analysis of coverage.out
24+
go tool cover -func coverage.out -o coverage.out
2825
- name: Go Coverage Badge
2926
uses: tj-actions/coverage-badge-go@v2
30-
if: ${{ runner.os == 'Linux' && matrix.go == '1.17' }} # Runs this on only one of the ci builds.
3127
with:
3228
green: 80
3329
filename: coverage.out

README.md

Lines changed: 48 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,25 @@
11
[![Go Reference](https://pkg.go.dev/badge/github.com/bengarrett/sauce.svg)](https://pkg.go.dev/github.com/bengarrett/sauce)   [![Go Report Card](https://goreportcard.com/badge/github.com/bengarrett/sauce)](https://goreportcard.com/report/github.com/bengarrett/sauce)
2-
![Coverage](https://img.shields.io/badge/Coverage-93.0%25-brightgreen)
2+
![Coverage](https://img.shields.io/badge/Coverage-93.0%25-brightgreen)   [![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
33

44
# Package sauce
55

6-
Package sauce is a [Go module](https://go.dev/) that parses SAUCE (Standard Architecture for
7-
Universal Comment Extensions) metadata.
6+
Package sauce is a [Go module](https://go.dev/) that parses SAUCE (Standard Architecture for Universal Comment Extensions) metadata.
87

9-
> The Standard Architecture for Universal Comment Extensions or SAUCE as it is
10-
more commonly known, is an architecture or protocol for attaching meta data
11-
or comments to files. Mainly intended for [ANSI art files](https://en.wikipedia.org/wiki/ANSI_art), SAUCE has always
12-
had provisions for many different file types.
8+
## Features
9+
10+
- ✅ Parse SAUCE metadata from files
11+
- ✅ Extract comprehensive file information (title, author, group, date, etc.)
12+
- ✅ Support multiple file types and data types
13+
- ✅ Extract type-specific information
14+
- ✅ Parse comment blocks
15+
- ✅ Serialize to JSON format
16+
- ✅ Format dates and sizes for human readability
17+
- ✅ Provide comprehensive error handling
18+
19+
> The Standard Architecture for Universal Comment Extensions, or SAUCE as it is
20+
more commonly known, is an architecture or protocol for attaching metadata
21+
or comments about files. Primarily designed for [ANSI art files](https://en.wikipedia.org/wiki/ANSI_art), SAUCE supports
22+
many different file types.
1323

1424
For the complete specification see:<br>
1525
http://www.acid.org/info/sauce/sauce.htm<br>
@@ -21,14 +31,14 @@ https://github.com/radman1/sauce<br>
2131
[Go Package with docs and examples.](https://pkg.go.dev/github.com/bengarrett/sauce)
2232

2333
```go
24-
// open a file
34+
// Open a file
2535
file, err := os.Open("artwork.ans")
2636
if err != nil {
2737
log.Fatal(err)
2838
}
2939
defer file.Close()
3040

31-
// read the file and create a SAUCE record
41+
// Read the file and create a SAUCE record
3242
sr, err := sauce.Read(file)
3343
if err != nil {
3444
log.Println(err)
@@ -85,35 +95,35 @@ The name of the group or company the creator is employed by.
8595
- - `type` - `FileType` value.
8696
- - `name` - `FileType` name.
8797

88-
- `typeInfo` - Type dependant information, see http://www.acid.org/info/sauce/sauce.htm#FileType.
89-
- - `1`
90-
- - - `value` - Value of `TInfo1`.
91-
- - - `info` - Human readable description of the value.
92-
- - `2`
93-
- - - `value` - Value of `TInfo2`.
94-
- - - `info` - Human readable description of the value.
95-
- - `3`
96-
- - - `value` - Value of `TInfo3`.
97-
- - - `info` - Human readable description of the value.
98-
99-
* - `flags` - Type dependant flags.
100-
* - - `decimal` - Value as an unsigned integer.
101-
* - - `binary` - Value in binary notation.
102-
- - - `nonBlinkMode` - Request ANSi non-blink mode (iCE Color).
103-
- - - - `flag` - Value as binary bit boolean ("0" or "1").
104-
- - - - `interpretation` - Human readable description of the value.
105-
* - - `letterSpacing` - ANSi letter-spacing to request 8 or 9 pixel font selection.
106-
* - - - `flag` - Value as a 2-bit binary string ("00", "01", "10").
107-
* - - - `interpretation` - Human readable description of the value.
108-
- - - `aspectRatio` - ANSi aspect ratio to request LCD square or CRT monitor style pixels.
109-
- - - - `flag` - Value as a 2-bit binary string ("00", "01", "10").
110-
- - - - `interpretation` - Human readable description of the value.
111-
* - `fontName` - The creator's preferred font to view the ANSi artwork, see http://www.acid.org/info/sauce/sauce.htm#FontName.
112-
113-
- `comments` - Comments or notes from the creator.
114-
- - `id` - SAUCE comment block identification, this should be "COMNT"
115-
- - `count`- The reported number of lines in the SAUCE comment block.
116-
- - `lines` - Lines of text, each line should comprise of 64 characters.
98+
- `typeInfo` - Type-dependent information, see http://www.acid.org/info/sauce/sauce.htm#FileType
99+
- `1`
100+
- `value` - Value of `TInfo1`
101+
- `info` - Human-readable description of the value
102+
- `2`
103+
- `value` - Value of `TInfo2`
104+
- `info` - Human-readable description of the value
105+
- `3`
106+
- `value` - Value of `TInfo3`
107+
- `info` - Human-readable description of the value
108+
109+
- `flags` - Type-dependent flags
110+
- `decimal` - Value as an unsigned integer
111+
- `binary` - Value in binary notation
112+
- `nonBlinkMode` - Request ANSI non-blink mode (iCE Color)
113+
- `flag` - Value as binary bit boolean ("0" or "1")
114+
- `interpretation` - Human-readable description of the value
115+
- `letterSpacing` - ANSI letter-spacing to request 8 or 9 pixel font selection
116+
- `flag` - Value as a 2-bit binary string ("00", "01", "10")
117+
- `interpretation` - Human-readable description of the value
118+
- `aspectRatio` - ANSI aspect ratio to request LCD square or CRT monitor style pixels
119+
- `flag` - Value as a 2-bit binary string ("00", "01", "10")
120+
- `interpretation` - Human-readable description of the value
121+
- `fontName` - The creator's preferred font to view the ANSI artwork, see http://www.acid.org/info/sauce/sauce.htm#FontName
122+
123+
- `comments` - Comments or notes from the creator
124+
- `id` - SAUCE comment block identification, this should be "COMNT"
125+
- `count` - The reported number of lines in the SAUCE comment block
126+
- `lines` - Lines of text, each line should comprise 64 characters
117127

118128
---
119129

0 commit comments

Comments
 (0)