Skip to content

Commit cec8cbb

Browse files
committed
first commit
0 parents  commit cec8cbb

26 files changed

+7566
-0
lines changed

.eslintignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
node_modules
2+
dist
3+
coverage
4+
**/*.d.ts
5+
tests

.eslintrc.js

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
module.exports = {
2+
extends: [
3+
'eslint:recommended',
4+
'plugin:@typescript-eslint/eslint-recommended',
5+
'plugin:@typescript-eslint/recommended',
6+
'plugin:prettier/recommended'
7+
],
8+
parser: '@typescript-eslint/parser',
9+
parserOptions: {
10+
project: 'tsconfig.json',
11+
sourceType: 'module'
12+
},
13+
plugins: ['@typescript-eslint'],
14+
rules: {
15+
'@typescript-eslint/naming-convention': [
16+
'error',
17+
{
18+
'selector': 'interface',
19+
'format': ['PascalCase'],
20+
'custom': {
21+
'regex': '^I[A-Z]',
22+
'match': true
23+
}
24+
}
25+
],
26+
'@typescript-eslint/no-unused-vars': ['warn', { args: 'none' }],
27+
'@typescript-eslint/no-explicit-any': 'off',
28+
'@typescript-eslint/no-namespace': 'off',
29+
'@typescript-eslint/no-use-before-define': 'off',
30+
'@typescript-eslint/quotes': [
31+
'error',
32+
'single',
33+
{ avoidEscape: true, allowTemplateLiterals: false }
34+
],
35+
curly: ['error', 'all'],
36+
eqeqeq: 'error',
37+
'prefer-arrow-callback': 'error'
38+
}
39+
};

.github/workflows/build.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches: main
6+
pull_request:
7+
branches: '*'
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v2
15+
16+
- name: Base Setup
17+
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
18+
19+
- name: Install dependencies
20+
run: python -m pip install -U jupyterlab~=3.1 check-manifest
21+
22+
- name: Build the extension
23+
run: |
24+
set -eux
25+
jlpm
26+
jlpm lint:check
27+
python -m pip install .
28+
29+
jupyter labextension list 2>&1 | grep -ie "jupyterlab-filesystem.*OK"
30+
python -m jupyterlab.browser_check
31+
32+
check-manifest -v
33+
34+
pip install build
35+
python -m build --sdist
36+
cp dist/*.tar.gz myextension.tar.gz
37+
pip uninstall -y "jupyterlab_filesystem" jupyterlab
38+
rm -rf myextension
39+
40+
- uses: actions/upload-artifact@v2
41+
with:
42+
name: myextension-sdist
43+
path: myextension.tar.gz
44+
45+
test_isolated:
46+
needs: build
47+
runs-on: ubuntu-latest
48+
49+
steps:
50+
- name: Checkout
51+
uses: actions/checkout@v2
52+
- name: Install Python
53+
uses: actions/setup-python@v2
54+
with:
55+
python-version: '3.8'
56+
architecture: 'x64'
57+
- uses: actions/download-artifact@v2
58+
with:
59+
name: myextension-sdist
60+
- name: Install and Test
61+
run: |
62+
set -eux
63+
# Remove NodeJS, twice to take care of system and locally installed node versions.
64+
sudo rm -rf $(which node)
65+
sudo rm -rf $(which node)
66+
pip install myextension.tar.gz
67+
pip install jupyterlab
68+
jupyter labextension list 2>&1 | grep -ie "jupyterlab-filesystem.*OK"
69+
python -m jupyterlab.browser_check --no-chrome-test

.github/workflows/check-release.yml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: Check Release
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
10+
permissions:
11+
contents: write
12+
13+
jobs:
14+
check_release:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v2
19+
- name: Install Python
20+
uses: actions/setup-python@v2
21+
with:
22+
python-version: 3.9
23+
architecture: 'x64'
24+
- name: Install node
25+
uses: actions/setup-node@v2
26+
with:
27+
node-version: '14.x'
28+
29+
30+
- name: Get pip cache dir
31+
id: pip-cache
32+
run: |
33+
echo "::set-output name=dir::$(pip cache dir)"
34+
- name: Cache pip
35+
uses: actions/cache@v1
36+
with:
37+
path: ${{ steps.pip-cache.outputs.dir }}
38+
key: ${{ runner.os }}-pip-${{ hashFiles('package.json') }}
39+
restore-keys: |
40+
${{ runner.os }}-pip-
41+
- name: Cache checked links
42+
uses: actions/cache@v2
43+
with:
44+
path: ~/.cache/pytest-link-check
45+
key: ${{ runner.os }}-linkcheck-${{ hashFiles('**/.md') }}-md-links
46+
restore-keys: |
47+
${{ runner.os }}-linkcheck-
48+
- name: Upgrade packaging dependencies
49+
run: |
50+
pip install --upgrade pip setuptools wheel jupyter-packaging~=0.10 --user
51+
- name: Install Dependencies
52+
run: |
53+
pip install .
54+
- name: Check Release
55+
uses: jupyter-server/jupyter_releaser/.github/actions/check-release@v1
56+
with:
57+
token: ${{ secrets.GITHUB_TOKEN }}
58+
59+
- name: Upload Distributions
60+
uses: actions/upload-artifact@v2
61+
with:
62+
name: jupyterlab_filesystem-releaser-dist-${{ github.run_number }}
63+
path: .jupyter_releaser_checkout/dist

.gitignore

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
*.bundle.*
2+
lib/
3+
node_modules/
4+
.eslintcache
5+
.stylelintcache
6+
*.egg-info/
7+
.ipynb_checkpoints
8+
*.tsbuildinfo
9+
jupyterlab_filesystem/labextension
10+
11+
# Created by https://www.gitignore.io/api/python
12+
# Edit at https://www.gitignore.io/?templates=python
13+
14+
### Python ###
15+
# Byte-compiled / optimized / DLL files
16+
__pycache__/
17+
*.py[cod]
18+
*$py.class
19+
20+
# C extensions
21+
*.so
22+
23+
# Distribution / packaging
24+
.Python
25+
build/
26+
develop-eggs/
27+
dist/
28+
downloads/
29+
eggs/
30+
.eggs/
31+
lib/
32+
lib64/
33+
parts/
34+
sdist/
35+
var/
36+
wheels/
37+
pip-wheel-metadata/
38+
share/python-wheels/
39+
.installed.cfg
40+
*.egg
41+
MANIFEST
42+
43+
# PyInstaller
44+
# Usually these files are written by a python script from a template
45+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
46+
*.manifest
47+
*.spec
48+
49+
# Installer logs
50+
pip-log.txt
51+
pip-delete-this-directory.txt
52+
53+
# Unit test / coverage reports
54+
htmlcov/
55+
.tox/
56+
.nox/
57+
.coverage
58+
.coverage.*
59+
.cache
60+
nosetests.xml
61+
coverage.xml
62+
*.cover
63+
.hypothesis/
64+
.pytest_cache/
65+
66+
# Translations
67+
*.mo
68+
*.pot
69+
70+
# Scrapy stuff:
71+
.scrapy
72+
73+
# Sphinx documentation
74+
docs/_build/
75+
76+
# PyBuilder
77+
target/
78+
79+
# pyenv
80+
.python-version
81+
82+
# celery beat schedule file
83+
celerybeat-schedule
84+
85+
# SageMath parsed files
86+
*.sage.py
87+
88+
# Spyder project settings
89+
.spyderproject
90+
.spyproject
91+
92+
# Rope project settings
93+
.ropeproject
94+
95+
# Mr Developer
96+
.mr.developer.cfg
97+
.project
98+
.pydevproject
99+
100+
# mkdocs documentation
101+
/site
102+
103+
# mypy
104+
.mypy_cache/
105+
.dmypy.json
106+
dmypy.json
107+
108+
# Pyre type checker
109+
.pyre/
110+
111+
# End of https://www.gitignore.io/api/python
112+
113+
# OSX files
114+
.DS_Store

.prettierignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
node_modules
2+
**/node_modules
3+
**/lib
4+
**/package.json
5+
jupyterlab_filesystem

.prettierrc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"singleQuote": true,
3+
"trailingComma": "none",
4+
"arrowParens": "avoid"
5+
}

.stylelintrc

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"extends": [
3+
"stylelint-config-recommended",
4+
"stylelint-config-standard",
5+
"stylelint-prettier/recommended"
6+
],
7+
"rules": {
8+
"property-no-vendor-prefix": null,
9+
"selector-no-vendor-prefix": null,
10+
"value-no-vendor-prefix": null,
11+
}
12+
}

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Changelog
2+
3+
<!-- <START NEW CHANGELOG ENTRY> -->
4+
5+
<!-- <END NEW CHANGELOG ENTRY> -->

LICENSE

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
BSD 3-Clause License
2+
3+
Copyright (c) 2022, JupyterLab Contrib Team
4+
All rights reserved.
5+
6+
Redistribution and use in source and binary forms, with or without
7+
modification, are permitted provided that the following conditions are met:
8+
9+
1. Redistributions of source code must retain the above copyright notice, this
10+
list of conditions and the following disclaimer.
11+
12+
2. Redistributions in binary form must reproduce the above copyright notice,
13+
this list of conditions and the following disclaimer in the documentation
14+
and/or other materials provided with the distribution.
15+
16+
3. Neither the name of the copyright holder nor the names of its
17+
contributors may be used to endorse or promote products derived from
18+
this software without specific prior written permission.
19+
20+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
23+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
24+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
26+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
27+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
28+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

0 commit comments

Comments
 (0)