Skip to content

Commit ce295cb

Browse files
committed
initial commit
0 parents  commit ce295cb

29 files changed

+6321
-0
lines changed

.editorconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 4
6+
charset = utf-8
7+
trim_trailing_whitespace = true
8+
insert_final_newline = true
9+
10+
[*.md]
11+
trim_trailing_whitespace = false

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/dist

.eslintrc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"extends": [
3+
"oclif",
4+
"oclif-typescript"
5+
]
6+
}

.github/dependabot.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: 'npm'
4+
directory: '/'
5+
schedule:
6+
interval: 'weekly'
7+
day: 'saturday'
8+
versioning-strategy: 'increase'
9+
labels:
10+
- 'dependencies'
11+
open-pull-requests-limit: 5
12+
pull-request-branch-name:
13+
separator: '-'
14+
commit-message:
15+
# cause a release for non-dev-deps
16+
prefix: fix(deps)
17+
# no release for dev-deps
18+
prefix-development: chore(dev-deps)
19+
ignore:
20+
- dependency-name: '@salesforce/dev-scripts'
21+
- dependency-name: '*'
22+
update-types: ['version-update:semver-major']

.github/workflows/automerge.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
name: automerge
2+
on:
3+
workflow_dispatch:
4+
schedule:
5+
- cron: '17 2,5,8,11 * * *'
6+
7+
jobs:
8+
automerge:
9+
uses: oclif/github-workflows/.github/workflows/automerge.yml@main
10+
secrets: inherit
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: failureNotifications
2+
3+
on:
4+
workflow_run:
5+
workflows:
6+
- version, tag and github release
7+
- publish
8+
types:
9+
- completed
10+
11+
jobs:
12+
failure-notify:
13+
runs-on: ubuntu-latest
14+
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
15+
steps:
16+
- name: Announce Failure
17+
id: slack
18+
uses: slackapi/[email protected]
19+
env:
20+
# for non-CLI-team-owned plugins, you can send this anywhere you like
21+
SLACK_WEBHOOK_URL: ${{ secrets.CLI_ALERTS_SLACK_WEBHOOK }}
22+
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK
23+
with:
24+
payload: |
25+
{
26+
"text": "${{ github.event.workflow_run.name }} failed: ${{ github.event.workflow_run.repository.name }}",
27+
"blocks": [
28+
{
29+
"type": "header",
30+
"text": {
31+
"type": "plain_text",
32+
"text": ":bh-alert: ${{ github.event.workflow_run.name }} failed: ${{ github.event.workflow_run.repository.name }} :bh-alert:"
33+
}
34+
},
35+
{
36+
"type": "section",
37+
"text": {
38+
"type": "mrkdwn",
39+
"text": "Repo: ${{ github.event.workflow_run.repository.html_url }}\nWorkflow name: `${{ github.event.workflow_run.name }}`\nJob url: ${{ github.event.workflow_run.html_url }}"
40+
}
41+
}
42+
]
43+
}

.github/workflows/manualRelease.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: manual release
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
release:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v3
11+
with:
12+
token: ${{ secrets.SVC_CLI_BOT_GITHUB_TOKEN }}
13+
- name: Conventional Changelog Action
14+
id: changelog
15+
uses: TriPSs/conventional-changelog-action@d360fad3a42feca6462f72c97c165d60a02d4bf2
16+
# overriding some of the basic behaviors to just get the changelog
17+
with:
18+
git-user-name: svc-cli-bot
19+
git-user-email: [email protected]
20+
github-token: ${{ secrets.SVC_CLI_BOT_GITHUB_TOKEN }}
21+
output-file: false
22+
# always do the release, even if there are no semantic commits
23+
skip-on-empty: false
24+
tag-prefix: ''
25+
- uses: notiz-dev/github-action-json-property@2192e246737701f108a4571462b76c75e7376216
26+
id: packageVersion
27+
with:
28+
path: 'package.json'
29+
prop_path: 'version'
30+
- name: Create Github Release
31+
uses: actions/create-release@v1
32+
env:
33+
GITHUB_TOKEN: ${{ secrets.SVC_CLI_BOT_GITHUB_TOKEN }}
34+
with:
35+
tag_name: ${{ steps.packageVersion.outputs.prop }}
36+
release_name: ${{ steps.packageVersion.outputs.prop }}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Pull Request Slack Notification
2+
3+
on:
4+
pull_request:
5+
types: [opened, reopened]
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Notify Slack on PR open
12+
env:
13+
WEBHOOK_URL : ${{ secrets.CLI_TEAM_SLACK_WEBHOOK_URL }}
14+
PULL_REQUEST_AUTHOR_ICON_URL : ${{ github.event.pull_request.user.avatar_url }}
15+
PULL_REQUEST_AUTHOR_NAME : ${{ github.event.pull_request.user.login }}
16+
PULL_REQUEST_AUTHOR_PROFILE_URL: ${{ github.event.pull_request.user.html_url }}
17+
PULL_REQUEST_BASE_BRANCH_NAME : ${{ github.event.pull_request.base.ref }}
18+
PULL_REQUEST_COMPARE_BRANCH_NAME : ${{ github.event.pull_request.head.ref }}
19+
PULL_REQUEST_NUMBER : ${{ github.event.pull_request.number }}
20+
PULL_REQUEST_REPO: ${{ github.event.pull_request.head.repo.name }}
21+
PULL_REQUEST_TITLE : ${{ github.event.pull_request.title }}
22+
PULL_REQUEST_URL : ${{ github.event.pull_request.html_url }}
23+
uses: salesforcecli/github-workflows/.github/actions/prNotification@main

.github/workflows/onPushToMain.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# test
2+
name: version, tag and github release
3+
4+
on:
5+
push:
6+
branches: [main]
7+
8+
jobs:
9+
release:
10+
uses: oclif/github-workflows/.github/workflows/githubRelease.yml@main
11+
secrets: inherit
12+
13+
# most repos won't use this
14+
# depends on previous job to avoid git collisions, not for any functionality reason
15+
# docs:
16+
# uses: salesforcecli/github-workflows/.github/workflows/publishTypedoc.yml@main
17+
# secrets: inherit
18+
# needs: release

.github/workflows/onRelease.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: publish
2+
3+
on:
4+
release:
5+
types: [released]
6+
# support manual release in case something goes wrong and needs to be repeated or tested
7+
workflow_dispatch:
8+
inputs:
9+
tag:
10+
description: tag that needs to publish
11+
type: string
12+
required: true
13+
jobs:
14+
npm:
15+
uses: oclif/github-workflows/.github/workflows/npmPublish.yml@main
16+
with:
17+
tag: latest
18+
githubTag: ${{ github.event.release.tag_name || inputs.tag }}
19+
secrets: inherit

.github/workflows/test.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
name: tests
2+
on:
3+
push:
4+
branches-ignore: [main]
5+
workflow_dispatch:
6+
7+
jobs:
8+
unit-tests:
9+
uses: oclif/github-workflows/.github/workflows/unitTest.yml@main

.gitignore

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
**/.DS_Store
2+
*-debug.log
3+
*-error.log
4+
/.idea
5+
/.nyc_output
6+
/dist
7+
/lib
8+
/package-lock.json
9+
/tmp
10+
node_modules
11+
oclif.manifest.json

.mocharc.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"require": [
3+
"test/helpers/init.js",
4+
"ts-node/register"
5+
],
6+
"watch-extensions": [
7+
"ts"
8+
],
9+
"recursive": true,
10+
"reporter": "spec",
11+
"timeout": 60000
12+
}

.vscode/launch.json

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"version": "0.2.0",
3+
"configurations": [
4+
{
5+
"type": "node",
6+
"request": "launch",
7+
"name": "Execute Command",
8+
"skipFiles": [
9+
"<node_internals>/**"
10+
],
11+
"program": "${workspaceFolder}/bin/dev",
12+
"args": [
13+
"hello",
14+
"world",
15+
],
16+
}
17+
]
18+
}

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2023 Donald Pakkies
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Create Formidable App
2+
A TypeScript & Imba Full-stack Framework for Nodejs.
3+
4+
The `create-formidable-app` CLI tool is a command-line interface tool that allows you to install Formidable in a fresh project. This installer is built on top of the [Formidable Installer](https://github.com/formidablejs/installer) package.
5+
6+
![npm](https://img.shields.io/npm/v/@formidablejs/installer)
7+
![GitHub](https://img.shields.io/github/license/formidablejs/installer)
8+
9+
## Official Documentation
10+
11+
Documentation for installing Formidable can be found on the [Formidable website](https://www.formidablejs.org/docs#your-first-formidable-application).
12+
13+
## Contributing
14+
15+
Thank you for considering contributing to the Formidable framework! The contribution guide can be found in the [Formidable documentation](https://www.formidablejs.org/docs/contributions).
16+
17+
## Code of Conduct
18+
19+
In order to ensure that the Formidable community is welcoming to all, please review and abide by the [Code of Conduct](https://www.formidablejs.org/docs/contributions#code-of-conduct).
20+
21+
## Security Vulnerabilities
22+
23+
If you discover a security vulnerability within Formidable, please send an e-mail to Donald Pakkies via [[email protected]](mailto:[email protected]). All security vulnerabilities will be promptly addressed.
24+
25+
## License
26+
27+
The Formidable framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).

bin/dev

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/usr/bin/env node
2+
3+
const oclif = require('@oclif/core')
4+
5+
const path = require('path')
6+
const project = path.join(__dirname, '..', 'tsconfig.json')
7+
8+
// In dev mode -> use ts-node and dev plugins
9+
process.env.NODE_ENV = 'development'
10+
11+
require('ts-node').register({project})
12+
13+
// In dev mode, always show stack traces
14+
oclif.settings.debug = true;
15+
16+
// Start the CLI
17+
oclif.run().then(oclif.flush).catch(oclif.Errors.handle)

bin/dev.cmd

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@echo off
2+
3+
node "%~dp0\dev" %*

bin/run

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env node
2+
3+
const oclif = require('@oclif/core')
4+
5+
oclif.run().then(require('@oclif/core/flush')).catch(require('@oclif/core/handle'))

bin/run.cmd

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@echo off
2+
3+
node "%~dp0\run" %*

0 commit comments

Comments
 (0)