Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: rewrite entire CLI in go #15

Merged
merged 15 commits into from
Jul 9, 2021
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
33 changes: 33 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Hardware/software**
- OS: [e.g. MacOS 11.2.3]
- Terminal type [i.e. Bash, or Zsh]
- Stream Machine CLI version [e.g. 1.0.0]
- Stream Machine flags (either from the config file, or environment variables).

**Additional context**
Add any other context about the problem here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''

---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
52 changes: 52 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Build

on:
release:
types:
- created

permissions:
contents: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.16
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
distribution: goreleaser
version: latest
args: --skip-publish --rm-dist
- name: Upload
env:
GITHUB_TOKEN: ${{secrets.GH_TOKEN}}
run: |
tag_name="${GITHUB_REF##*/}"
hub release edit $(find dist -type f -name "*.tar.gz" -printf "-a %p ") -a "dist/checksums.txt" -m "" "$tag_name"
- name: Upload Homebrew formula
env:
GITHUB_TOKEN: ${{secrets.GH_TOKEN}}
APIS_USERNAME: ${{secrets.APIS_USERNAME}}
APIS_EMAIL: ${{secrets.APIS_EMAIL}}
run: |
git config --global user.email "${APIS_EMAIL}"
git config --global user.name "${APIS_USERNAME}"
tag_name="${GITHUB_REF##*/}"
cd dist
git clone "https://git:${GITHUB_TOKEN}@github.com/streammachineio/homebrew-cli.git"
cp -f strm.rb homebrew-cli
cd homebrew-cli
git add .
git commit -m "Release brew formula for Stream Machine CLI ${tag_name}"
git push
git tag -a "${tag_name}" -m "Release brew formula for Stream Machine CLI ${tag_name}"
git push --tags
224 changes: 0 additions & 224 deletions .github/workflows/cli-release.yaml

This file was deleted.

30 changes: 30 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Release

on:
push:
branches:
- "master"

jobs:
release:
name: Release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: 12
- name: Install dependencies
run: npm i --non-interactive --pure-lockfile
- name: Release
env:
GITHUB_TOKEN: ${{secrets.GH_TOKEN}}
GIT_AUTHOR_NAME: ${{secrets.APIS_USERNAME}}
GIT_COMMITTER_NAME: ${{secrets.APIS_USERNAME}}
GIT_AUTHOR_EMAIL: ${{secrets.APIS_EMAIL}}
GIT_COMMITTER_EMAIL: ${{secrets.APIS_EMAIL}}
run: npm run semantic-release -- --repository-url "$(git config --get remote.origin.url)"
12 changes: 9 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
.idea
target
dependency-reduced-pom.xml
*.log
node_modules
strm
strm2
protos
.env
.env-dev
.env-prod
.default-login-token.json
dist
Loading