Skip to content

Commit 59c5c85

Browse files
committed
Initial commit
0 parents  commit 59c5c85

File tree

102 files changed

+19450
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+19450
-0
lines changed

.browserslistrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
> 0.25%
2+
not dead

.editorconfig

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# top-most EditorConfig file
2+
root = true
3+
4+
# Unix-style newlines with a newline ending every file
5+
[*]
6+
end_of_line = lf
7+
insert_final_newline = true
8+
9+
# Matches multiple files with brace expansion notation
10+
# Set default charset
11+
[*.{js,py}]
12+
charset = utf-8
13+
14+
# 4 space indentation
15+
[*.py]
16+
indent_style = space
17+
indent_size = 4
18+
19+
# Tab indentation (no size specified)
20+
[Makefile]
21+
indent_style = tab
22+
23+
# Indentation override for all JS under lib directory
24+
[src/**.{js,ts}]
25+
indent_style = space
26+
indent_size = 2
27+
28+
# Matches the exact files either package.json or .travis.yml
29+
[{package.json,.travis.yml}]
30+
indent_style = space
31+
indent_size = 2
32+

.eslintignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
node_modules
2+
dist
3+
coverage

.eslintrc.js

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
module.exports = {
2+
env: {
3+
es6: true,
4+
browser: true,
5+
webextensions: true,
6+
},
7+
parser: "@typescript-eslint/parser",
8+
parserOptions: {
9+
'ecmaVersion': 9,
10+
'sourceType': 'module',
11+
'tsconfigRootDir': __dirname,
12+
'project': './tsconfig.json',
13+
},
14+
extends: [
15+
'eslint:recommended',
16+
'plugin:@typescript-eslint/recommended',
17+
'plugin:@typescript-eslint/recommended-requiring-type-checking',
18+
'plugin:prettier/recommended'
19+
],
20+
plugins: [
21+
'@typescript-eslint',
22+
'simple-import-sort',
23+
'svelte3',
24+
'prettier'
25+
],
26+
overrides: [
27+
{
28+
files: ['*.svelte'],
29+
processor: 'svelte3/svelte3'
30+
}
31+
],
32+
rules: {
33+
'@typescript-eslint/no-non-null-assertion': 'off',
34+
'simple-import-sort/sort': [
35+
'error',
36+
{
37+
groups: [
38+
// Configuration based on https://github.com/lydell/eslint-plugin-simple-import-sort/blob/7b29c07/examples/.eslintrc.js#L71-L89
39+
// Packages.
40+
["^svelte", "^@?\\w"],
41+
// Internal packages.
42+
["^(@Treetop)(/.*|$)"],
43+
// Side effect imports.
44+
["^\\u0000"],
45+
// Parent imports. Put `..` last.
46+
["^\\.\\.(?!/?$)", "^\\.\\./?$"],
47+
// Other relative imports. Put same-folder imports and `.` last.
48+
["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
49+
// Style imports.
50+
["^.+\\.s?css$"],
51+
]
52+
}
53+
],
54+
'prettier/prettier': 'error'
55+
}
56+
};

.github/workflows/node.js.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: '**'
6+
pull_request:
7+
branches: '**'
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Use Node.js
15+
uses: actions/setup-node@v1
16+
with:
17+
node-version: '14.x'
18+
- run: npm ci
19+
- run: npm run lint
20+
- run: npm run validate
21+
- run: npm test

.github/workflows/release.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
on:
2+
push:
3+
tags:
4+
- 'v*'
5+
6+
name: Release
7+
8+
jobs:
9+
build:
10+
name: Upload Release Asset
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout code
14+
uses: actions/checkout@v2
15+
- name: Set output filename
16+
id: set-filename
17+
run: echo ::set-output name=filename::treetop-${GITHUB_REF#refs/*/}.zip
18+
- name: Use Node.js
19+
uses: actions/setup-node@v1
20+
with:
21+
node-version: '14.x'
22+
- run: npm ci
23+
- run: npm run build
24+
- run: npx web-ext build --no-input=true --filename "${{ steps.set-filename.outputs.filename}}"
25+
- name: Create Release
26+
id: create_release
27+
uses: actions/create-release@v1
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30+
with:
31+
tag_name: ${{ github.ref }}
32+
release_name: ${{ github.ref }}
33+
draft: false
34+
prerelease: false
35+
- name: Upload Release Asset
36+
id: upload-release-asset
37+
uses: actions/upload-release-asset@v1
38+
env:
39+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
40+
with:
41+
upload_url: ${{ steps.create_release.outputs.upload_url }}
42+
asset_path: ./web-ext-artifacts/${{ steps.set-filename.outputs.filename}}
43+
asset_name: ${{ steps.set-filename.outputs.filename}}
44+
asset_content_type: application/zip

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
coverage/
2+
dist/
3+
node_modules/
4+
web-ext-artifacts/
5+
.vscode/

.prettierrc.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
singleQuote = true
2+
svelteAllowShorthand = true
3+
svelteBracketNewLine = false
4+
svelteSortOrder = "scripts-styles-markup"
5+
svelteStrictMode = false

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Treetop Changelog
2+
All notable changes to this project will be documented in this file.
3+
4+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
5+
6+
## [Unreleased]
7+
8+
## [0.1.0] - 2020-11
9+
### Added
10+
- Initial release.
11+
12+
[Unreleased]: https://github.com/msmolens/treetop/compare/v0.1.0...HEAD
13+
[0.1.0]: https://github.com/msmolens/treetop/releases/tag/v0.1.0

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) 2020 Max Smolens
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.

0 commit comments

Comments
 (0)