Skip to content
This repository has been archived by the owner on Sep 9, 2022. It is now read-only.

Commit

Permalink
update: rename core to scc, update tasks, and update configs
Browse files Browse the repository at this point in the history
  • Loading branch information
abdfnx committed Apr 6, 2022
1 parent 7abf31a commit 241f814
Show file tree
Hide file tree
Showing 46 changed files with 50 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@
"golang.go",
"bbenoist.Nix"
],
"postCreateCommand": "go mod tidy && cd core && yarn",
"postCreateCommand": "go mod tidy && cd scc && yarn",
"remoteUser": "userx"
}
8 changes: 7 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@ updates:
reviewers:
- abdfnx
- package-ecosystem: npm
directory: "/core"
directory: "/scc"
schedule:
interval: "daily"
reviewers:
- abdfnx
- package-ecosystem: npm
directory: "/hub"
schedule:
interval: "daily"
reviewers:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ jobs:

- name: Building From Source
run: |
task build-core
task link-core
task build-scc
task link-scc
.\scripts\bfs.ps1
echo "::add-path::C:\Users\runneradmin\AppData\Local\secman\bin\;"
Expand Down
17 changes: 12 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Release
on:
push:
tags:
- '*'
- "*"

env:
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
Expand All @@ -30,17 +30,24 @@ jobs:
with:
node-version: 16

- name: Set up Tag
id: ghtag
run: echo ::set-output name=tag::${GITHUB_REF#refs/*/}
- name: Set up `Task`
uses: arduino/setup-task@v1

- name: Set up GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
install-only: true

- name: Set up Date
run: go run ./scripts/date.go >> date.txt
run: task set-tag-and-date

- name: Build
run: BuildDate="$(cat date.txt)" goreleaser release --rm-dist --timeout 100m

- name: Build SMUI
run: task build-smui

- name: Upload SMUI
uses: softprops/action-gh-release@v1
with:
files: smui.zip
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ vendor
# Builds, Secman CLI Core Lib, Cache and Tmp
.cache
dist
core/lib
scc/lib
tmp

# Other
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
| Project | Package | Version | Links |
| ----------- | ------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------- |
| **CLI** | [`scmn-dev/secman`](https://pkg.go.dev/github.com/scmn-dev/secman/v6) | ![version](https://img.shields.io/github/v/release/scmn-dev/secman?label=go%40latest&logo=go&style=flat-square) | [`README.md`](README.md) |
| **Core** | [`@secman/core`](https://github.com/scmn-dev/secman/tree/main/core) | ![version)](https://img.shields.io/github/package-json/v/scmn-dev/secman?color=blue&filename=core%2Fpackage.json&label=npm%40latest&logo=npm&logoColor=blue&style=flat-square) | [`README.md`](core/README.md) |
| **Scc** | [`@secman/scc`](https://github.com/scmn-dev/secman/tree/main/scc) | ![version)](https://img.shields.io/github/package-json/v/scmn-dev/secman?color=blue&filename=scc%2Fpackage.json&label=npm%40latest&logo=npm&logoColor=blue&style=flat-square) | [`README.md`](scc/README.md) |
| **Hub** | [`@secman/hub`](https://github.com/scmn-dev/secman/tree/main/hub) | ![version](https://img.shields.io/github/package-json/v/scmn-dev/secman?filename=hub%2Fpackage.json&label=npm%40latest&logo=npm&style=flat-square) | [`README.md`](hub/README.md) |
| **Crypto** | [`@secman/crypto`](https://github.com/scmn-dev/secman/tree/main/crypto) | ![version)](https://img.shields.io/github/package-json/v/scmn-dev/secman?color=blue&filename=crypto%2Fpackage.json&label=npm%40latest&logo=npm&logoColor=blue&style=flat-square) | [`README.md`](crypto/README.md) |

Expand Down
25 changes: 17 additions & 8 deletions Taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,28 @@ tasks:
- go mod tidy -compat=1.18
- go build -ldflags "-X main.version=$(cat tag.txt) -X main.buildDate=$(cat date.txt)" -o secman

build-core:
dir: ./core
build-scc:
dir: ./scc
cmds:
- if ! [ -d ./node_modules ]; then yarn; fi
- yarn build

link-core:
dir: ./core
build-smui:
dir: ./hub
cmds:
- task: set-tag-and-date
- yarn build
- mv dist ui
- cp tag.txt ui
- zip -9 -r smui.zip ui

link-scc:
dir: ./scc
cmds:
- npm link

publish-core:
dir: ./core
publish-scc:
dir: ./scc
cmds:
- yarn publish

Expand All @@ -56,6 +65,6 @@ tasks:
desc: build from source
cmds:
- task: build
- task: build-core
- task: link-core
- task: build-scc
- task: link-scc
- task: install
3 changes: 3 additions & 0 deletions crypto/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Secman Crypto

> A library for encrypting and decrypting data using in Secman products.
4 changes: 2 additions & 2 deletions crypto/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@secman/crypto",
"version": "0.0.1",
"description": "Secman Crypto",
"version": "0.0.2",
"description": "A library for encrypting and decrypting data using in Secman products.",
"main": "./main.ts",
"types": "./main.ts",
"license": "MIT",
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@
"secrets"
],
"workspaces": [
"core",
"hub",
"crypto",
"hub",
"scc",
"tools/spinner"
],
"scripts": {
"dev": "turbo run dev --parallel",
"build": "turbo run build",
"clean": "rimraf node_modules && cd core && rimraf node_modules && cd ../hub && rimraf node_modules && cd ../crypto && rimraf node_modules && cd ../tools/spinner && rimraf node_modules && cd ../.."
"clean": "rimraf node_modules && cd scc && rimraf node_modules && cd ../hub && rimraf node_modules && cd ../crypto && rimraf node_modules && cd ../tools/spinner && rimraf node_modules && cd ../.."
},
"author": {
"name": "Secman, Inc.",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion core/package.json → scc/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@secman/scc",
"description": "The command-line interface of Secman Core.",
"version": "0.1.1",
"version": "0.1.2",
"main": "lib/index.js",
"license": "MIT",
"homepage": "https://secman.dev",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 241f814

Please sign in to comment.