-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Use goravel console command (#2)
* use goravel console in installer * add flags to new command * add support to nested directory * add support to nested directory * add generate method * optimize readme * add version * remove unnecessary files * update go.mod * add test case for `NewCommand` * add .github folder * use master branch of framework * Optimize style * Remove code * use spinner * add spinner test * remove local replace of framework * Update console/commands/new_command.go * Update console/commands/new_command.go --------- Co-authored-by: Wenbo han <wenbo.han@compass.com>
- Loading branch information
1 parent
b408c12
commit 815ebeb
Showing
15 changed files
with
525 additions
and
211 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: Please submit to goravel/goravel (请提交至 goravel/goravel) | ||
url: https://github.com/goravel/goravel/issues/new/choose | ||
about: Thanks in advance for your feedback (提前感谢您的反馈) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file | ||
version: 2 | ||
updates: | ||
- package-ecosystem: gomod | ||
directory: / | ||
labels: | ||
- "🤖 Dependencies" | ||
schedule: | ||
interval: daily | ||
groups: | ||
go-modules: | ||
patterns: | ||
- "*" | ||
open-pull-requests-limit: 100 | ||
- package-ecosystem: github-actions | ||
directory: / | ||
labels: | ||
- "🤖 Dependencies" | ||
schedule: | ||
interval: daily | ||
groups: | ||
github-actions: | ||
patterns: | ||
- "*" | ||
open-pull-requests-limit: 100 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: Codecov | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
jobs: | ||
codecov: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: 'stable' | ||
- name: Install dependencies | ||
run: go mod tidy | ||
- name: Run tests with coverage | ||
run: go test -coverprofile="coverage.out" $(go list ./... | grep -v /mocks | grep -v /facades | grep -v /contracts | grep -v /testing/mock) | ||
- name: Print coverage report | ||
run: go tool cover -func=coverage.out | ||
- name: Upload coverage report to Codecov | ||
uses: codecov/codecov-action@v4 | ||
with: | ||
file: ./coverage.out | ||
token: ${{ secrets.CODECOV }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: Lint | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
permissions: | ||
contents: read | ||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: 'stable' | ||
cache: false | ||
- name: go mod pakcage cache | ||
uses: actions/cache@v4 | ||
with: | ||
path: ~/go/pkg/mod | ||
key: ${{ runner.os }}-go-${{ hashFiles('go.mod') }} | ||
- name: Install dependencies | ||
run: go mod tidy | ||
- name: Lint | ||
uses: golangci/golangci-lint-action@v6 | ||
with: | ||
skip-cache: true | ||
skip-pkg-cache: true | ||
skip-build-cache: true | ||
version: latest | ||
args: --timeout=30m ./... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
name: PR Check Title | ||
on: | ||
pull_request: | ||
jobs: | ||
pr-check-title: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: Slashgear/action-check-pr-title@v4.3.0 | ||
with: | ||
regexp: "^(feat|fix|docs|style|refactor|perf|test|workflow|build|ci|chore|types|wip|release|revert)(\\(.+\\))?!?: .+" | ||
helpMessage: "Your PR title is invalid. Please follow the Conventional Commits specification: https://www.conventionalcommits.org/en/v1.0.0/" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Test | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
jobs: | ||
test: | ||
strategy: | ||
matrix: | ||
go: | ||
- "1.21" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ matrix.go }} | ||
- name: go mod pakcage cache | ||
uses: actions/cache@v4 | ||
with: | ||
path: ~/go/pkg/mod | ||
key: ${{ runner.os }}-go-${{ matrix.go }}-${{ hashFiles('go.mod') }} | ||
- name: Install dependencies | ||
run: go mod tidy | ||
- name: Run tests | ||
run: go test ./... | ||
windows: | ||
strategy: | ||
matrix: | ||
go: | ||
- "1.21" | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ matrix.go }} | ||
- name: go mod pakcage cache | ||
uses: actions/cache@v4 | ||
with: | ||
path: ~/go/pkg/mod | ||
key: ${{ runner.os }}-go-${{ matrix.go }}-${{ hashFiles('go.mod') }} | ||
- name: Install dependencies | ||
run: go mod tidy | ||
- name: Run tests | ||
run: go test ./... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,33 @@ | ||
# installer | ||
# Goravel Installer | ||
|
||
[![Doc](https://pkg.go.dev/badge/github.com/goravel/installer)](https://pkg.go.dev/github.com/goravel/installer) | ||
[![Go](https://img.shields.io/github/go-mod/go-version/goravel/installer)](https://go.dev/) | ||
[![Release](https://img.shields.io/github/release/goravel/installer.svg)](https://github.com/goravel/installer/releases) | ||
[![Test](https://github.com/goravel/installer/actions/workflows/test.yml/badge.svg)](https://github.com/goravel/installer/actions) | ||
[![Report Card](https://goreportcard.com/badge/github.com/goravel/installer)](https://goreportcard.com/report/github.com/goravel/installer) | ||
[![Codecov](https://codecov.io/gh/goravel/gin/branch/master/graph/badge.svg)](https://codecogin/v.io/gh/goravel/installer) | ||
![License](https://img.shields.io/github/license/goravel/installer) | ||
|
||
Goravel Installer is a command-line tool that helps you to install the Goravel framework. | ||
|
||
## Version | ||
|
||
| goravel/installer | goravel/framework | | ||
|-------------------|-------------------| | ||
| v1.1.x | v1.13.x | | ||
|
||
## Installation | ||
|
||
```bash | ||
go install -u github.com/goravel/installer | ||
``` | ||
|
||
## Usage | ||
|
||
```bash | ||
goravel new blog | ||
``` | ||
|
||
## License | ||
|
||
Goravel Installer is open-source software licensed under the [MIT license](https://opensource.org/licenses/MIT). |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.