Skip to content

Commit b09028b

Browse files
committed
First template run
1 parent 4e25928 commit b09028b

30 files changed

+1762
-18
lines changed

.github/workflows/go.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Go
2+
3+
on:
4+
pull_request:
5+
branches: [ master ]
6+
7+
jobs:
8+
9+
build:
10+
name: Build
11+
runs-on: self-hosted
12+
steps:
13+
14+
- name: Set up Go 1.x
15+
uses: actions/setup-go@v2
16+
with:
17+
go-version: ^1.13
18+
id: go
19+
20+
- name: Check out code into the Go module directory
21+
uses: actions/checkout@v2
22+
23+
- name: Get dependencies
24+
run: |
25+
go get -v -t -d ./...
26+
if [ -f Gopkg.toml ]; then
27+
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
28+
dep ensure
29+
fi
30+
31+
- name: Install
32+
run: make install
33+
34+
- name: Check
35+
run: make check

.github/workflows/publish.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Publish Release
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
7+
jobs:
8+
9+
build:
10+
name: Build
11+
runs-on: self-hosted
12+
steps:
13+
14+
- name: Set up Go 1.x
15+
uses: actions/setup-go@v2
16+
with:
17+
go-version: ^1.13
18+
id: go
19+
20+
- name: Check out code into the Go module directory
21+
uses: actions/checkout@v2
22+
23+
- name: Get dependencies
24+
run: |
25+
go get -v -t -d ./...
26+
if [ -f Gopkg.toml ]; then
27+
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
28+
dep ensure
29+
fi
30+
31+
- name: Install
32+
run: make install
33+
34+
- name: Check
35+
run: make check
36+
37+
- name: Docker
38+
run: make docker
39+
40+
- name: Docker push
41+
run: docker push moov/irs

.gitignore

Lines changed: 35 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,35 @@
1-
.DS_Store
1+
# Compiled Object files, Static and Dynamic libs (Shared Objects)
2+
*.o
3+
*.a
4+
*.so
5+
6+
# Folders
7+
_obj
8+
_test
9+
10+
# Architecture specific extensions/prefixes
11+
*.[568vq]
12+
[568vq].out
13+
14+
*.cgo1.go
15+
*.cgo2.c
16+
_cgo_defun.c
17+
_cgo_gotypes.go
18+
_cgo_export.*
19+
20+
_testmain.go
21+
22+
*.exe
23+
*.test
24+
*.prof
25+
bin/
26+
*.db
27+
28+
/lint-project.sh
29+
misspell*
30+
staticcheck*
31+
coverage.txt
32+
33+
pkger*
34+
pkged.go
35+
cover.out

.openapi-generator/VERSION

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
5.0.0-SNAPSHOT
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
inputSpec: /local/api/api.yml
2+
outputDir: /local/pkg/client
3+
generatorName: go
4+
artifactId: "irs-client"
5+
gitUserId: moov-io
6+
gitRepoId: "irs"
7+
additionalProperties:
8+
isGoSubmodule: true
9+
packageName: client

Dockerfile

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
FROM debian:buster AS runtime
2+
WORKDIR /
3+
4+
RUN apt-get update && apt-get install -y ca-certificates \
5+
&& rm -rf /var/lib/apt/lists/*
6+
7+
COPY bin/.docker/irs /app/irs
8+
VOLUME [ "/data", "/configs" ]
9+
10+
EXPOSE 8208/tcp
11+
EXPOSE 8209/tcp
12+
13+
VOLUME [ "/data", "/configs" ]
14+
15+
ENTRYPOINT ["/app/irs"]

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright [yyyy] [name of copyright owner]
189+
Copyright 2020 Moov, LLC
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

Makefile

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
PLATFORM=$(shell uname -s | tr '[:upper:]' '[:lower:]')
2+
VERSION := $(shell grep -Eo '(v[0-9]+[\.][0-9]+[\.][0-9]+(-[a-zA-Z0-9]*)?)' version.go)
3+
4+
USERID := $(shell id -u $$USER)
5+
GROUPID:= $(shell id -g $$USER)
6+
7+
build: irs
8+
9+
irs:
10+
pkger
11+
go build -o ${PWD}/bin/irs cmd/irs/*
12+
13+
run: irs
14+
./bin/irs
15+
16+
test: services build
17+
go test -cover ./...
18+
19+
services:
20+
-docker-compose up -d --force-recreate
21+
22+
install:
23+
go get github.com/markbates/pkger/cmd/pkger
24+
git checkout LICENSE
25+
26+
.PHONY: check
27+
check: build services
28+
ifeq ($(OS),Windows_NT)
29+
@echo "Skipping checks on Windows, currently unsupported."
30+
else
31+
@wget -O lint-project.sh https://raw.githubusercontent.com/moov-io/infra/master/go/lint-project.sh
32+
@chmod +x ./lint-project.sh
33+
./lint-project.sh
34+
endif
35+
36+
docker: install
37+
pkger
38+
GOOS=linux GOARCH=amd64 CGO_ENABLED=1 go build -o ${PWD}/bin/.docker/irs cmd/irs/*
39+
docker build --pull -t moov/irs:$(VERSION) -f Dockerfile .
40+
docker tag moov/irs:$(VERSION) moov/irs:latest
41+
42+
docker-run:
43+
docker run -v ${PWD}/data:/data -v ${PWD}/configs:/configs --env APP_CONFIG="/configs/config.yml" -it --rm moov/irs:$(VERSION)
44+
45+
clean:
46+
rm ./data/*
47+
48+
# Generate the go code from the public and internal api's
49+
openapitools:
50+
docker run --rm \
51+
-u $(USERID):$(GROUPID) \
52+
-e OPENAPI_GENERATOR_VERSION='4.2.0' \
53+
-v ${PWD}:/local openapitools/openapi-generator-cli batch -- /local/.openapi-generator/client-generator-config.yml
54+
55+
# From https://github.com/genuinetools/img
56+
.PHONY: AUTHORS
57+
AUTHORS:
58+
@$(file >$@,# This file lists all individuals having contributed content to the repository.)
59+
@$(file >>$@,# For how it is generated, see `make AUTHORS`.)
60+
@echo "$(shell git log --format='\n%aN <%aE>' | LC_ALL=C.UTF-8 sort -uf)" >> $@

README.md

Lines changed: 45 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,54 @@
1-
# irs
2-
Package `github.com/moov-io/irs` implements a file reader and writer written in Go along with a HTTP API and CLI for creating, parsing, validating, and transforming IRS electronic Filing Information Returns Electronically (FIRE). FIRE operates on a byte(ASCII) level making it difficult to interface with JSON and CSV/TEXT file formats.
1+
moov-io/irs
2+
===
33

4-
| Input | Output |
5-
|------------|------------|
6-
| JSON | JSON |
7-
| ASCII FIRE | ASCII FIRE |
8-
| | PDF Form |
9-
| | SQL |
4+
[![GoDoc](https://godoc.org/github.com/moov-io/irs?status.svg)](https://godoc.org/github.com/moov-io/irs)
5+
[![Build Status](https://travis-ci.com/moov-io/irs.svg?branch=master)](https://travis-ci.com/moov-io/irs)
6+
[![Coverage Status](https://codecov.io/gh/moov-io/irs/branch/master/graph/badge.svg)](https://codecov.io/gh/moov-io/irs)
7+
[![Go Report Card](https://goreportcard.com/badge/github.com/moov-io/irs)](https://goreportcard.com/report/github.com/moov-io/irs)
8+
[![Apache 2 licensed](https://img.shields.io/badge/license-Apache2-blue.svg)](https://raw.githubusercontent.com/moov-io/irs/master/LICENSE)
109

10+
Package github.com/moov-io/irs implements a file reader and writer written in Go along with a HTTP API and
11+
CLI for creating, parsing, validating, and transforming IRS electronic Filing Information Returns
12+
Electronically (FIRE). FIRE operates on a byte(ASCII) level making it difficult to interface with JSON and
13+
CSV/TEXT file formats.
1114

12-
- [Filing Information Returns Electronically (FIRE)](https://www.irs.gov/e-file-providers/filing-information-returns-electronically-fire)
13-
- File formats are defined by Part C of [IRS Publication 1220](https://www.irs.gov/pub/irs-pdf/p1220.pdf)
1415

15-
# Project Status
16+
Docs: [docs](docs/README.md) | [open api specification](api/api.yml)
1617

17-
We are just getting started!
18+
## Project Status
1819

19-
- [ ] 1099-MISC [About Form 1099-MISC](https://www.irs.gov/forms-pubs/about-form-1099-misc)
20-
- [ ] 1099-NEC [About Form 1099-NEC](https://www.irs.gov/forms-pubs/about-form-1099-nec)
20+
This project is currently under development and could introduce breaking changes to reach a stable status. We are looking for community feedback so please try out our code or give us feedback!
2121

22+
## Getting Started
2223

24+
Read through the [project docs](docs/README.md) over here to get an understanding of the purpose of this project and how to run it.
2325

24-
... more to come
26+
## Getting Help
27+
28+
channel | info
29+
------- | -------
30+
[Project Documentation](https://docs.moov.io/) | Our project documentation available online.
31+
Google Group [moov-users](https://groups.google.com/forum/#!forum/moov-users)| The Moov users Google group is for contributors other people contributing to the Moov project. You can join them without a google account by sending an email to [[email protected]](mailto:[email protected]). After receiving the join-request message, you can simply reply to that to confirm the subscription.
32+
Twitter [@moov_io](https://twitter.com/moov_io) | You can follow Moov.IO's Twitter feed to get updates on our project(s). You can also tweet us questions or just share blogs or stories.
33+
[GitHub Issue](https://github.com/moov-io) | If you are able to reproduce a problem please open a GitHub Issue under the specific project that caused the error.
34+
[moov-io slack](https://slack.moov.io/) | Join our slack channel to have an interactive discussion about the development of the project.
35+
36+
## Supported and Tested Platforms
37+
38+
- 64-bit Linux (Ubuntu, Debian), macOS, and Windows
39+
40+
## Contributing
41+
42+
Yes please! Please review our [Contributing guide](CONTRIBUTING.md) and [Code of Conduct](https://github.com/moov-io/ach/blob/master/CODE_OF_CONDUCT.md) to get started! Checkout our [issues for first time contributors](https://github.com/moov-io/irs/contribute) for something to help out with.
43+
44+
This project uses [Go Modules](https://github.com/golang/go/wiki/Modules) and uses Go 1.14 or higher. See [Golang's install instructions](https://golang.org/doc/install) for help setting up Go. You can download the source code and we offer [tagged and released versions](https://github.com/moov-io/irs/releases/latest) as well. We highly recommend you use a tagged release for production.
45+
46+
### Test Coverage
47+
48+
Improving test coverage is a good candidate for new contributors while also allowing the project to move more quickly by reducing regressions issues that might not be caught before a release is pushed out to our users. One great way to improve coverage is by adding edge cases and different inputs to functions (or [contributing and running fuzzers](https://github.com/dvyukov/go-fuzz)).
49+
50+
Tests can run processes (like sqlite databases), but should only do so locally.
51+
52+
## License
53+
54+
Apache License 2.0 See [LICENSE](LICENSE) for details.

0 commit comments

Comments
 (0)