Skip to content

Commit

Permalink
Merge pull request #369 from drone/drone2
Browse files Browse the repository at this point in the history
Merging drone2 branch into master
  • Loading branch information
Dan Wilson authored Aug 20, 2021
2 parents ac1349f + 995f61c commit 639a5bd
Show file tree
Hide file tree
Showing 471 changed files with 141,931 additions and 39,519 deletions.
3 changes: 3 additions & 0 deletions .commitlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": ["@commitlint/config-conventional"]
}
8 changes: 8 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# ENV Variables
REACT_APP_DRONE_SERVER=
REACT_APP_DRONE_TOKEN=

# For macOS and Linux
SASS_PATH=node_modules:src
# For Windows
SASS_PATH=./node_modules;./src
41 changes: 41 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"extends": ["react-app", "airbnb", "airbnb/hooks", "airbnb/whitespace"],
"rules": {
"max-len": [1, {
"code": 120,
"ignoreTemplateLiterals": true,
"ignoreComments": true
}],
"jsx-a11y/label-has-associated-control": [2, {
"assert": "htmlFor"
}],
"react/jsx-props-no-spreading": "off",
"react/jsx-sort-props": [
"warn",
{
"callbacksLast": true,
"shorthandLast": true,
"noSortAlphabetically": true
}
],
"import/order": [
"warn",
{
"groups": ["builtin", "external", "internal", "parent", "sibling", "index"],
"newlines-between": "always",
"alphabetize": {
"order": "asc",
"caseInsensitive": true
}
}
],
"import/prefer-default-export": "off"
},
"settings": {
"import/resolver": {
"node": {
"moduleDirectory":["node_modules", "src/"]
}
}
}
}
38 changes: 32 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,33 @@
node_modules
dist/files/*
*.txt
*.log
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build
/dist/files
/dist/*_gen.go

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
/.vscode

# .git
.eslintcache

.env
.env.*
hermione
.env.development.local
.env.local
3 changes: 3 additions & 0 deletions .huskyrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"hooks": {}
}
4 changes: 4 additions & 0 deletions .lintstagedrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"*.{js,jsx}": "eslint --fix --ignore-path .gitignore",
"*.{css,sass,scss,md,html}": "stylelint --fix --ignore-path .gitignore"
}
18 changes: 18 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"extends": [
"stylelint-config-standard",
"stylelint-config-recommended-scss",
"stylelint-config-css-modules",
"stylelint-config-recess-order"
],
"rules": {
"no-descending-specificity": null,
"at-rule-no-unknown": null,
"scss/at-rule-no-unknown": [
true,
{
"ignoreAtRules": ["value"]
}
]
}
}
71 changes: 53 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,70 @@
# drone-ui
## Drone UI

## Configuration
### Getting started

Create a `.env.development.local` file with the drone server address (no trailing slash) and your drone user token:
1. **Clone this repository**

```
VUE_APP_DRONE_SERVER=https://drone.company.com
VUE_APP_DRONE_TOKEN=f0af17449a83681de22db7ce16672f16
```
```bash
git clone https://github.com/drone/drone-ui.git
```

## Project setup
```
npm install
2. **Install dependencies**

```bash
npm install
```

3. **Copy .env.example and rename it into .env**

```bash
cp .env.example .env.development.local
```

4. **Fill required variables. For example:**

```text
REACT_APP_DRONE_SERVER=https://drone.company.com
REACT_APP_DRONE_TOKEN=<your_drone_token>
```

### Run the app

```bash
npm run start
```

### Compiles and hot-reloads for development
### Build the app

```bash
npm run build
```

### Run the built app

```bash
npm run serve
```

### Compiles and minifies for production
### Run linters

```bash
npm run lint
```
npm run build

### Run linters and fix auto fixable problems

```bash
npm run lint:fix
```

### Run your tests
```

```bash
npm run test
```

### Lints and fixes files
```
npm run lint
```
## Commits

We use Conventional Commits for commit messages. You can read more about Conventional Commits [here](https://www.conventionalcommits.org/en/v1.0.0/). [Here](https://cheatography.com/albelop/cheat-sheets/conventional-commits/) you can find a useful Conventional Commits Cheat Sheet.

We try to make our commits "atomic". [Here](https://www.freshconsulting.com/atomic-commits/) and [here](https://en.wikipedia.org/wiki/Atomic_commit) you can read more about Atomic commits.
3 changes: 0 additions & 3 deletions babel.config.js

This file was deleted.

1 change: 0 additions & 1 deletion dist/dist.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
package dist

//go:generate togo http -package dist -output dist_gen.go

Loading

0 comments on commit 639a5bd

Please sign in to comment.