Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .copywrite.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
schema_version = 1

project {
license = "MIT"
copyright_year = 2026
copyright_holder = "Forward Email"

header_ignore = [
# GitHub issue template configuration
".github/ISSUE_TEMPLATE/*.yml",

# golangci-lint tooling configuration
".golangci.yml",
]
}

1 change: 0 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,3 @@ indent_size = 2
[*.{tf,tfvars,tpl}]
indent_style = space
indent_size = 2

1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* text=auto eol=lf
83 changes: 83 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: Bug Report
description: Report a bug in the Forward Email Go SDK
title: "[Bug]: "
labels: ["bug", "triage"]
body:
- type: markdown
attributes:
value: |
Thanks for taking the time to report a bug! Please fill out the sections below to help us understand and reproduce the issue.

- type: textarea
id: description
attributes:
label: Bug Description
description: A clear and concise description of what the bug is.
placeholder: Describe the bug...
validations:
required: true

- type: textarea
id: expected
attributes:
label: Expected Behavior
description: What did you expect to happen?
placeholder: I expected...
validations:
required: true

- type: textarea
id: actual
attributes:
label: Actual Behavior
description: What actually happened?
placeholder: Instead, what happened was...
validations:
required: true

- type: textarea
id: reproduction
attributes:
label: Steps to Reproduce
description: Please provide minimal code or steps to reproduce the issue.
placeholder: |
1. Create client with...
2. Call method...
3. See error...
validations:
required: true

- type: input
id: go-version
attributes:
label: Go Version
description: What version of Go are you using? (run `go version`)
placeholder: go1.21.0
validations:
required: true

- type: dropdown
id: os
attributes:
label: Operating System
description: What operating system are you using?
options:
- Linux
- macOS
- Windows
- Other
validations:
required: true

- type: textarea
id: logs
attributes:
label: Relevant Log Output
description: Please copy and paste any relevant log output. This will be automatically formatted into code.
render: shell

- type: textarea
id: additional
attributes:
label: Additional Context
description: Add any other context about the problem here.
47 changes: 47 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Feature Request
description: Suggest a new feature or enhancement for the Forward Email Go SDK
title: "[Feature]: "
labels: ["enhancement", "triage"]
body:
- type: markdown
attributes:
value: |
Thanks for suggesting a feature! Please fill out the sections below to help us understand your request.

- type: textarea
id: problem
attributes:
label: Problem Statement
description: Is your feature request related to a problem? Please describe.
placeholder: I'm always frustrated when...
validations:
required: true

- type: textarea
id: solution
attributes:
label: Proposed Solution
description: Describe the solution you'd like to see.
placeholder: I would like...
validations:
required: true

- type: textarea
id: alternatives
attributes:
label: Alternatives Considered
description: Describe any alternative solutions or features you've considered.
placeholder: I also considered...

- type: textarea
id: code-example
attributes:
label: Example Usage
description: If applicable, show how you'd like to use this feature.
render: go

- type: textarea
id: additional
attributes:
label: Additional Context
description: Add any other context or screenshots about the feature request here.
21 changes: 21 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
## what

<!--
- Describe high-level what changed as a result of these commits (i.e. in plain-english, what do these changes mean?)
- Use bullet points to be concise and to the point.
-->

## why

<!--
- Provide the justifications for the changes.
- Describe why these changes were made (e.g. why do these commits fix the problem?)
- Use bullet points to be concise and to the point.
-->

## references

<!--
- Link to any supporting github issues or helpful documentation to add some context (e.g. stackoverflow).
- Use `closes #123`, if this PR closes a GitHub issue `#123`
-->
31 changes: 0 additions & 31 deletions .github/workflows/ci.yml

This file was deleted.

47 changes: 47 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Forward Email SDK Tests

# This GitHub action runs your tests for each pull request and push.
on:
pull_request:
paths:
- "forwardemail/**.go"
- "go.mod"
- "go.sum"
- ".github/workflows/tests.yml"
push:
branches:
- main

permissions:
contents: read

jobs:
build:
name: Build
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0
with:
go-version-file: 'go.mod'
cache: true
- run: go mod tidy
- run: go mod download
- run: go build -v ./...

sdk-tests:
name: SDK Unit Tests
needs: build
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0
with:
go-version-file: 'go.mod'
cache: true
- name: Download Dependencies
run: go mod download
- name: Run SDK Tests
run: go test -v -race -coverprofile=coverage.out ./forwardemail/...
1 change: 1 addition & 0 deletions .go-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.25
1 change: 0 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,4 +83,3 @@ output:
- file
# Show statistics
show-stats: true

48 changes: 48 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Copyright Forward Email 2026
# SPDX-License-Identifier: Apache-2.0

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
args: [--allow-multiple-documents]
- id: check-added-large-files
args: [--maxkb=500]
- id: check-merge-conflict

- repo: https://github.com/tekwizely/pre-commit-golang
rev: v1.0.0-rc.1
hooks:
- id: go-fumpt
args: [-w]

- id: go-build-mod

- id: go-mod-tidy

- repo: local
hooks:
- id: golangci-lint-config-verify
name: golangci-lint config verify
entry: golangci-lint config verify --config .golangci.yml
language: system
pass_filenames: false
files: ^\.golangci\.yml$

- id: golangci-lint
name: golangci-lint
entry: golangci-lint run --fix
language: system
types: [go]
pass_filenames: false

- id: go-test
name: go test
entry: go test -race ./...
language: system
types: [go]
pass_filenames: false
stages: [pre-push]
1 change: 1 addition & 0 deletions Brewfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
brew "go"
brew "gofumpt"
brew "golangci-lint"
brew "pre-commit"
3 changes: 3 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Code of Conduct

Please defer to the [GitHub Contributor Code of Conduct](https://github.com/github/.github/blob/master/CODE_OF_CONDUCT.md).
3 changes: 3 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Contributing

Please defer to the [GitHub Contributing document](https://github.com/github/.github/blob/master/CONTRIBUTING.md).
Loading
Loading