Skip to content

Commit 8e1ec3f

Browse files
committed
Added new features
Signed-off-by: vviveksharma <visharma@progress.com>
1 parent bce6f94 commit 8e1ec3f

46 files changed

Lines changed: 3749 additions & 141 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
---
2+
name: Bug Report
3+
about: Report a bug to help us improve GoForge
4+
title: '[BUG] '
5+
labels: bug
6+
assignees: ''
7+
---
8+
9+
## Bug Description
10+
A clear and concise description of the bug.
11+
12+
## Steps to Reproduce
13+
1. Run `goforge create ...`
14+
2. ...
15+
3. See error
16+
17+
## Expected Behavior
18+
What you expected to happen.
19+
20+
## Actual Behavior
21+
What actually happened.
22+
23+
## Environment
24+
- **OS**: [e.g., macOS 14, Ubuntu 22.04]
25+
- **Go version**: [e.g., 1.26.2]
26+
- **GoForge version**: [e.g., 1.0.0]
27+
- **Server type**: [e.g., fiber, gin]
28+
29+
## Error Output
30+
```
31+
Paste any error messages here
32+
```
33+
34+
## Additional Context
35+
Any other context about the problem.
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
name: Feature Request
3+
about: Suggest a new feature for GoForge
4+
title: '[FEATURE] '
5+
labels: enhancement
6+
assignees: ''
7+
---
8+
9+
## Feature Description
10+
A clear and concise description of the feature you'd like.
11+
12+
## Use Case
13+
Describe the problem this feature would solve.
14+
15+
## Proposed Solution
16+
How you think this could be implemented.
17+
18+
## Alternatives Considered
19+
Any alternative solutions or features you've considered.
20+
21+
## Additional Context
22+
Any other context, screenshots, or examples.

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
## Pull Request
2+
3+
### Description
4+
<!-- Describe your changes in detail -->
5+
6+
### Type of change
7+
<!-- Mark the relevant option with an "x" -->
8+
9+
- [ ] 🐛 Bug fix (non-breaking change which fixes an issue)
10+
- [ ] ✨ New feature (non-breaking change which adds functionality)
11+
- [ ] 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)
12+
- [ ] 📝 Documentation update
13+
- [ ] 🧪 Test update
14+
- [ ] 🔧 Configuration change
15+
- [ ] ♻️ Code refactoring
16+
17+
### Checklist
18+
<!-- Mark completed items with an "x" -->
19+
20+
- [ ] My code follows the style guidelines of this project
21+
- [ ] I have performed a self-review of my own code
22+
- [ ] I have commented my code, particularly in hard-to-understand areas
23+
- [ ] I have made corresponding changes to the documentation
24+
- [ ] My changes generate no new warnings
25+
- [ ] I have added tests that prove my fix is effective or that my feature works
26+
- [ ] New and existing unit tests pass locally with my changes
27+
- [ ] Any dependent changes have been merged and published
28+
29+
### Testing
30+
<!-- Describe the tests you ran and how to reproduce them -->
31+
32+
```bash
33+
# Example commands to test
34+
go test ./...
35+
./goforge create test-project --server fiber
36+
```
37+
38+
### Screenshots (if applicable)
39+
<!-- Add screenshots to help explain your changes -->
40+
41+
### Related Issues
42+
<!-- Link related issues here. Use "Fixes #123" to auto-close issues -->
43+
44+
Fixes #

.github/dependabot.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
version: 2
2+
3+
updates:
4+
# GitHub Actions
5+
- package-ecosystem: "github-actions"
6+
directory: "/"
7+
schedule:
8+
interval: "weekly"
9+
day: "monday"
10+
open-pull-requests-limit: 5
11+
labels:
12+
- "dependencies"
13+
- "github-actions"
14+
15+
# Go modules
16+
- package-ecosystem: "gomod"
17+
directory: "/"
18+
schedule:
19+
interval: "weekly"
20+
day: "monday"
21+
open-pull-requests-limit: 5
22+
labels:
23+
- "dependencies"
24+
- "go"
25+
groups:
26+
# Group all patch and minor updates together
27+
minor-patch:
28+
patterns:
29+
- "*"
30+
update-types:
31+
- "minor"
32+
- "patch"

.github/workflows/codeql.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: CodeQL
2+
3+
on:
4+
push:
5+
branches: [ main, develop ]
6+
pull_request:
7+
branches: [ main, develop ]
8+
schedule:
9+
- cron: '0 0 * * 0' # Weekly on Sundays
10+
11+
jobs:
12+
analyze:
13+
name: Analyze
14+
runs-on: ubuntu-latest
15+
permissions:
16+
actions: read
17+
contents: read
18+
security-events: write
19+
20+
strategy:
21+
fail-fast: false
22+
matrix:
23+
language: [ 'go' ]
24+
25+
steps:
26+
- name: Checkout repository
27+
uses: actions/checkout@v4
28+
29+
- name: Initialize CodeQL
30+
uses: github/codeql-action/init@v3
31+
with:
32+
languages: ${{ matrix.language }}
33+
queries: +security-and-quality
34+
35+
- name: Autobuild
36+
uses: github/codeql-action/autobuild@v3
37+
38+
- name: Perform CodeQL Analysis
39+
uses: github/codeql-action/analyze@v3
40+
with:
41+
category: "/language:${{ matrix.language }}"

.github/workflows/lint.yml

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
name: Lint
2+
3+
on:
4+
push:
5+
branches: [ main, develop ]
6+
pull_request:
7+
branches: [ main, develop ]
8+
9+
jobs:
10+
golangci:
11+
name: golangci-lint
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v4
17+
18+
- name: Set up Go
19+
uses: actions/setup-go@v5
20+
with:
21+
go-version: '1.26.x'
22+
cache: false # golangci-lint action has its own cache
23+
24+
- name: golangci-lint
25+
uses: golangci/golangci-lint-action@v4
26+
with:
27+
version: latest
28+
args: --timeout=5m --verbose
29+
30+
gofmt:
31+
name: gofmt
32+
runs-on: ubuntu-latest
33+
34+
steps:
35+
- name: Checkout code
36+
uses: actions/checkout@v4
37+
38+
- name: Set up Go
39+
uses: actions/setup-go@v5
40+
with:
41+
go-version: '1.26.x'
42+
43+
- name: Run gofmt
44+
run: |
45+
if [ "$(gofmt -s -l . | wc -l)" -gt 0 ]; then
46+
echo "The following files are not formatted:"
47+
gofmt -s -l .
48+
exit 1
49+
fi
50+
51+
govet:
52+
name: go vet
53+
runs-on: ubuntu-latest
54+
55+
steps:
56+
- name: Checkout code
57+
uses: actions/checkout@v4
58+
59+
- name: Set up Go
60+
uses: actions/setup-go@v5
61+
with:
62+
go-version: '1.26.x'
63+
64+
- name: Run go vet
65+
run: go vet ./...
66+
67+
staticcheck:
68+
name: staticcheck
69+
runs-on: ubuntu-latest
70+
71+
steps:
72+
- name: Checkout code
73+
uses: actions/checkout@v4
74+
75+
- name: Set up Go
76+
uses: actions/setup-go@v5
77+
with:
78+
go-version: '1.26.x'
79+
80+
- name: Install staticcheck
81+
run: go install honnef.co/go/tools/cmd/staticcheck@latest
82+
83+
- name: Run staticcheck
84+
run: staticcheck ./...

.github/workflows/test.yml

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
name: Tests
2+
3+
on:
4+
push:
5+
branches: [ main, develop ]
6+
pull_request:
7+
branches: [ main, develop ]
8+
9+
jobs:
10+
test:
11+
name: Test
12+
runs-on: ${{ matrix.os }}
13+
strategy:
14+
matrix:
15+
os: [ubuntu-latest, macos-latest]
16+
go-version: ['1.26.x']
17+
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v4
21+
22+
- name: Set up Go
23+
uses: actions/setup-go@v5
24+
with:
25+
go-version: ${{ matrix.go-version }}
26+
cache: true
27+
28+
- name: Download dependencies
29+
run: go mod download
30+
31+
- name: Verify dependencies
32+
run: go mod verify
33+
34+
- name: Run tests
35+
run: go test -v -race -coverprofile=coverage.out -covermode=atomic ./...
36+
37+
- name: Upload coverage to Codecov
38+
uses: codecov/codecov-action@v4
39+
if: matrix.os == 'ubuntu-latest'
40+
with:
41+
files: ./coverage.out
42+
flags: unittests
43+
name: codecov-goforge
44+
fail_ci_if_error: false
45+
46+
- name: Generate coverage report
47+
if: matrix.os == 'ubuntu-latest'
48+
run: go tool cover -html=coverage.out -o coverage.html
49+
50+
- name: Upload coverage HTML
51+
if: matrix.os == 'ubuntu-latest'
52+
uses: actions/upload-artifact@v4
53+
with:
54+
name: coverage-report
55+
path: coverage.html
56+
retention-days: 7
57+
58+
lint:
59+
name: Lint
60+
runs-on: ubuntu-latest
61+
62+
steps:
63+
- name: Checkout code
64+
uses: actions/checkout@v4
65+
66+
- name: Set up Go
67+
uses: actions/setup-go@v5
68+
with:
69+
go-version: '1.26.x'
70+
cache: true
71+
72+
- name: golangci-lint
73+
uses: golangci/golangci-lint-action@v4
74+
with:
75+
version: latest
76+
args: --timeout=5m
77+
78+
build:
79+
name: Build
80+
runs-on: ${{ matrix.os }}
81+
strategy:
82+
matrix:
83+
os: [ubuntu-latest, macos-latest, windows-latest]
84+
go-version: ['1.26.x']
85+
86+
steps:
87+
- name: Checkout code
88+
uses: actions/checkout@v4
89+
90+
- name: Set up Go
91+
uses: actions/setup-go@v5
92+
with:
93+
go-version: ${{ matrix.go-version }}
94+
cache: true
95+
96+
- name: Build
97+
run: go build -v -o goforge ./cmd/goforge
98+
99+
- name: Verify build
100+
if: runner.os != 'Windows'
101+
run: ./goforge version
102+
103+
- name: Verify build (Windows)
104+
if: runner.os == 'Windows'
105+
run: .\goforge.exe version

0 commit comments

Comments
 (0)