Compare commits
269 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| f67562c8ac | |||
| e4682d493e | |||
| e4afa91517 | |||
| 9b8134441c | |||
| d16bc0a1ef | |||
| 3a54763a53 | |||
| 81177f27ce | |||
| f1e5244ee2 | |||
| e30bdcd6cf | |||
| 0615d39c61 | |||
| d3bb430a98 | |||
| 3eac7da736 | |||
| 1f16dcdbf0 | |||
| fe433ad929 | |||
| 96c172c1ff | |||
| 6fd2ba027c | |||
| 85d50e183f | |||
| aa3fd27451 | |||
| c15d443595 | |||
| cdc9e40d0b | |||
| e3fd433c9b | |||
| 3969b22310 | |||
| 58ff5ccc5a | |||
| 74533cc9b9 | |||
| 0cd8d6c0d1 | |||
| 7a654ffad8 | |||
| 703225acdd | |||
| 8c3b9f0ca6 | |||
| 0b40b2dee8 | |||
| afe65f5e34 | |||
| fa14e6fbfe | |||
| 7968d84047 | |||
| a2fe9e239a | |||
| a6f849d0f5 | |||
| 4869be90b8 | |||
| ddca7cc92e | |||
| 12fc16e71f | |||
| d8014e94b8 | |||
| 54d05237ed | |||
| 60037aec07 | |||
| 8378fe9eb1 | |||
| 8acbc35562 | |||
| 30deaa961b | |||
| 0d120cd51d | |||
| 86213539f7 | |||
| 94b921fbe2 | |||
| f62b4b7804 | |||
| be89eda130 | |||
| 79d2d781b0 | |||
| 3619d3375e | |||
| 70a942faee | |||
| 4c3ff7c1bb | |||
| 00e78de6f3 | |||
| 0eba2547cc | |||
| febfec0e36 | |||
| c191899971 | |||
| a87e823a9c | |||
| 5f1232e8b8 | |||
| c5bdfe13fa | |||
| d8f6796249 | |||
| 5610154ff9 | |||
| 669abfb38a | |||
| 124154e4e9 | |||
| 545a9ff9f3 | |||
| 57d5804a33 | |||
| 675c64368a | |||
| b1191ffae5 | |||
| e4ac2ed95f | |||
| d784c1cb79 | |||
| ced70cee93 | |||
| b54472aa93 | |||
| fddc5b7c89 | |||
| 195da823b1 | |||
| 2685146634 | |||
| 39aced4f8e | |||
| 56463f999d | |||
| bfbe69fb14 | |||
| 5c47fc1aae | |||
| a858023e39 | |||
| 1228d53827 | |||
| 3acd8ff2d6 | |||
| a9171987c3 | |||
| 82cab2c498 | |||
| 78921cfa48 | |||
| fd8bdac192 | |||
| 304dcae79d | |||
| 692fe08353 | |||
| ddf00fc06a | |||
| e4ad9d3302 | |||
| f4e75d8079 | |||
| 6e997e5491 | |||
| babb81e49b | |||
| 0e0fa2e798 | |||
| eaab7e68d4 | |||
| a944b6ef33 | |||
| c15bbc9aed | |||
| 08f3a0b590 | |||
| 647f8a22cc | |||
| ee930c9fa3 | |||
| faa37adde2 | |||
| 33ab03fbd6 | |||
| 2a9025302e | |||
| 87e25628fa | |||
| 1009ed5132 | |||
| 95df217bf8 | |||
| b7e1f8bc94 | |||
| f7f35a01df | |||
| bca29b7a23 | |||
| 1b2439a0b6 | |||
| 7e7d40b77f | |||
| 6c3ecc1392 | |||
| 65d34bffe3 | |||
| 1aecf03aac | |||
| 71fb6fed1a | |||
| 8120e3bd48 | |||
| 8abd2402ac | |||
| ce631f12af | |||
| 226687cd73 | |||
| c6def3842f | |||
| c562a275c6 | |||
| 9e567d0548 | |||
| eb36ac50fd | |||
| f4f13753f3 | |||
| b1e1f3f5d1 | |||
| 3e1b3131d6 | |||
| e1d10a022c | |||
| 992147f5e6 | |||
| 74f2ce8b81 | |||
| 7a76e7054a | |||
| 4cb55cc417 | |||
| 275c9880e0 | |||
| cd6b6b7add | |||
| 054edd5c22 | |||
| 6894260a83 | |||
| 1d33f89196 | |||
| 532beb7d21 | |||
| 4f16929836 | |||
| 554a26b301 | |||
| fcb0823bed | |||
| f8b6fcf508 | |||
| 0ca8e60d3d | |||
| ee42a03882 | |||
| 635fc85b2e | |||
| cef8ee4578 | |||
| 5e7ad92690 | |||
| 3ee069b6fc | |||
| 29d2eeeeaf | |||
| 52ea415139 | |||
| 4bdd76960b | |||
| 6c3542795e | |||
| d30cdb608e | |||
| d581829a2d | |||
| 7c33cc83d6 | |||
| d886159234 | |||
| 4e708c4ec8 | |||
| 6e8e030a5d | |||
| 0665f8ed09 | |||
| f62175f73f | |||
| 84522247b3 | |||
| 5265de2598 | |||
| 78e4a2df68 | |||
| 16e1557d44 | |||
| e4c0ce6ef3 | |||
| b4fa440dea | |||
| 0a2f3213c4 | |||
| d47d36cde6 | |||
| 1d1e51c134 | |||
| 5eb1f577bb | |||
| 4d7e333604 | |||
| cb1d29fbe8 | |||
| 41f44c06c0 | |||
| b28b27b187 | |||
| 559c8d6574 | |||
| 2aa4c57ae7 | |||
| f0771e1003 | |||
| 239e6c6a65 | |||
| 64d4e014a1 | |||
| a9eab4ab5e | |||
| a62b9eadde | |||
| ca8646527c | |||
| f662462072 | |||
| 30cbe757d3 | |||
| 39a5ab8ff9 | |||
| 0777c9eb99 | |||
| 7a4b225934 | |||
| 479452b271 | |||
| 2fb00d6eeb | |||
| 02362ade1e | |||
| 249b972406 | |||
| 81a9321531 | |||
| cf6e1d2e62 | |||
| 5f5cfd26db | |||
| 60ed9c664b | |||
| 190287cd72 | |||
| e443cda701 | |||
| 8ec77904db | |||
| e2227f3a6c | |||
| 84fb11cf4a | |||
| 3eb7ab4cd4 | |||
| 0e8d39f0c1 | |||
| 559223da39 | |||
| 5d6b14acc7 | |||
| 58e1b1d9c3 | |||
| 32bfc62714 | |||
| bf09ddbac0 | |||
| 59261999f0 | |||
| 663b1cb364 | |||
| aa9bba4755 | |||
| f55c48eb4e | |||
| 1cddb4d88a | |||
| 944b7368d0 | |||
| 295745ed3b | |||
| 16c19e915c | |||
| 7a74aeac9a | |||
| 47da521a15 | |||
| 2f300a0ab6 | |||
| 7aa4310359 | |||
| 51d6bed019 | |||
| 92f922ff93 | |||
| 82025b9624 | |||
| 014ef099f2 | |||
| febc36ef36 | |||
| 9a7217cbb6 | |||
| 64c8d8d77e | |||
| 7bebd66b20 | |||
| 7d8e82a7de | |||
| 89c1150c7d | |||
| 65a1db8157 | |||
| c7bb134cff | |||
| 640ba2fbf5 | |||
| c21ddcdd2e | |||
| 910c941222 | |||
| 6d6c56b87c | |||
| 96f27dadd7 | |||
| 0a380910dc | |||
| 98ab84e21f | |||
| 4cd0e6a1e3 | |||
| 27ef2b1e7f | |||
| 6b46502e81 | |||
| cc8a946cd6 | |||
| 7580bcb90a | |||
| 07e384f98d | |||
| 5765b0e00b | |||
| f6a8250db8 | |||
| b94da7e56c | |||
| b89a824004 | |||
| b7845de2cb | |||
| 2f7b7645e3 | |||
| 6f4502389e | |||
| 636e769e56 | |||
| d239610e81 | |||
| e82de8da2a | |||
| 5232607549 | |||
| 1bacb3f46d | |||
| 6bf71399a3 | |||
| 4951107d89 | |||
| 5581e178a5 | |||
| d688b9d34a | |||
| dfe13b5ad5 | |||
| eded025bd5 | |||
| 04ae797578 | |||
| e38cf200b9 | |||
| 51d0d54771 | |||
| 664740860b | |||
| 8440fd8275 | |||
| 084e4239b4 | |||
| 9f0c85e8d3 | |||
| 66ea0ee96d | |||
| 5489463885 |
40
.drone.yml
40
.drone.yml
@@ -1,6 +1,13 @@
|
|||||||
kind: pipeline
|
kind: pipeline
|
||||||
|
type: ssh
|
||||||
name: default
|
name: default
|
||||||
|
|
||||||
|
server:
|
||||||
|
host: build.gextra.net
|
||||||
|
user: root
|
||||||
|
ssh_key:
|
||||||
|
from_secret: ssh_key_secret
|
||||||
|
|
||||||
trigger:
|
trigger:
|
||||||
event:
|
event:
|
||||||
- tag
|
- tag
|
||||||
@@ -9,16 +16,10 @@ steps:
|
|||||||
- name: build
|
- name: build
|
||||||
image: node
|
image: node
|
||||||
commands:
|
commands:
|
||||||
|
- npm install -g vsce
|
||||||
- npm ci
|
- npm ci
|
||||||
- vsce package
|
- vsce package
|
||||||
|
|
||||||
# - name: gitea_release
|
|
||||||
# environment:
|
|
||||||
# GITEA_TOKEN:
|
|
||||||
# from_secret: gitea_token
|
|
||||||
# commands:
|
|
||||||
# - bash gitearelease.sh
|
|
||||||
|
|
||||||
- name: gitea_release
|
- name: gitea_release
|
||||||
image: plugins/gitea-release
|
image: plugins/gitea-release
|
||||||
settings:
|
settings:
|
||||||
@@ -26,28 +27,3 @@ steps:
|
|||||||
files: ./*.vsix
|
files: ./*.vsix
|
||||||
api_key:
|
api_key:
|
||||||
from_secret: gitea_token
|
from_secret: gitea_token
|
||||||
|
|
||||||
# - name: deploy
|
|
||||||
# environment:
|
|
||||||
# PASSWORD:
|
|
||||||
# from_secret: password
|
|
||||||
# when:
|
|
||||||
# status:
|
|
||||||
# - success
|
|
||||||
# - failure
|
|
||||||
# commands:
|
|
||||||
# - |
|
|
||||||
# curl --fail-with-body -s -X POST \
|
|
||||||
# --data-urlencode "digest=$(docker inspect registry.raphaelpiccolo.com/$DRONE_REPO_NAME:latest | jq -r '.[0].RepoDigests[0]' | cut -d@ -f 2)" \
|
|
||||||
# --data-urlencode "start=$DRONE_BUILD_CREATED" \
|
|
||||||
# --data-urlencode "url=$DRONE_BUILD_LINK" \
|
|
||||||
# --data-urlencode "buildNumber=$DRONE_BUILD_NUMBER" \
|
|
||||||
# --data-urlencode "version=$DRONE_TAG" \
|
|
||||||
# --data-urlencode "name=$DRONE_REPO_NAME" \
|
|
||||||
# --data-urlencode "size=$(docker inspect -f '{{ .Size }}' "$DRONE_REPO_NAME")" \
|
|
||||||
# --data-urlencode "status=$DRONE_BUILD_STATUS" \
|
|
||||||
# "https://admin:$PASSWORD@monitoring.raphaelpiccolo.com/fr/dronehook"
|
|
||||||
|
|
||||||
# - name: test
|
|
||||||
# commands:
|
|
||||||
# - docker run --rm cvtest npm test
|
|
||||||
|
|||||||
@@ -1,30 +0,0 @@
|
|||||||
{
|
|
||||||
"root": true,
|
|
||||||
"parser": "@typescript-eslint/parser",
|
|
||||||
"parserOptions": {
|
|
||||||
"ecmaVersion": 6,
|
|
||||||
"sourceType": "module"
|
|
||||||
},
|
|
||||||
"plugins": [
|
|
||||||
"@typescript-eslint"
|
|
||||||
],
|
|
||||||
"rules": {
|
|
||||||
"@typescript-eslint/naming-convention": [
|
|
||||||
"warn",
|
|
||||||
{
|
|
||||||
"selector": "import",
|
|
||||||
"format": [ "camelCase", "PascalCase" ]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"@typescript-eslint/semi": "warn",
|
|
||||||
"curly": "warn",
|
|
||||||
"eqeqeq": "warn",
|
|
||||||
"no-throw-literal": "warn",
|
|
||||||
"semi": "off"
|
|
||||||
},
|
|
||||||
"ignorePatterns": [
|
|
||||||
"out",
|
|
||||||
"dist",
|
|
||||||
"**/*.d.ts"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -30,3 +30,4 @@ coverage/
|
|||||||
.local/
|
.local/
|
||||||
.config/
|
.config/
|
||||||
data/
|
data/
|
||||||
|
.aider*
|
||||||
|
|||||||
66
eslint.config.js
Normal file
66
eslint.config.js
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
import js from '@eslint/js';
|
||||||
|
import tsparser from '@typescript-eslint/parser';
|
||||||
|
import tsplugin from '@typescript-eslint/eslint-plugin';
|
||||||
|
import globals from 'globals';
|
||||||
|
|
||||||
|
export default [
|
||||||
|
js.configs.recommended,
|
||||||
|
{
|
||||||
|
files: ['**/*.ts'],
|
||||||
|
languageOptions: {
|
||||||
|
parser: tsparser,
|
||||||
|
parserOptions: {
|
||||||
|
ecmaVersion: 6,
|
||||||
|
sourceType: 'module',
|
||||||
|
},
|
||||||
|
globals: {
|
||||||
|
...globals.browser,
|
||||||
|
...globals.node,
|
||||||
|
...globals.mocha,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
plugins: {
|
||||||
|
'@typescript-eslint': tsplugin,
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
'@typescript-eslint/naming-convention': [
|
||||||
|
'warn',
|
||||||
|
{
|
||||||
|
selector: 'import',
|
||||||
|
format: ['camelCase', 'PascalCase'],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
'curly': 'warn',
|
||||||
|
'eqeqeq': 'warn',
|
||||||
|
'no-throw-literal': 'warn',
|
||||||
|
'semi': 'off',
|
||||||
|
// Règles générales réutilisées de flatbay
|
||||||
|
'prefer-const': ['error', { destructuring: 'all' }],
|
||||||
|
'no-var': 'error',
|
||||||
|
'object-shorthand': ['error', 'properties'],
|
||||||
|
'prefer-template': 'error',
|
||||||
|
'dot-notation': 'error',
|
||||||
|
'no-unused-expressions': 'error',
|
||||||
|
'no-nested-ternary': 'error',
|
||||||
|
'one-var-declaration-per-line': ['error', 'always'],
|
||||||
|
'one-var': ['error', 'never'],
|
||||||
|
'vars-on-top': 'error',
|
||||||
|
'yoda': 'error',
|
||||||
|
'prefer-arrow-callback': 'error',
|
||||||
|
'no-implicit-globals': 'error',
|
||||||
|
'no-labels': 'error',
|
||||||
|
'no-new-func': 'error',
|
||||||
|
'no-script-url': 'error',
|
||||||
|
'no-sequences': 'error',
|
||||||
|
'no-unused-labels': 'error',
|
||||||
|
'prefer-spread': 'error',
|
||||||
|
'no-console': 0, // Garder les console.log pour debug
|
||||||
|
'no-empty': 0,
|
||||||
|
'no-redeclare': 0,
|
||||||
|
'no-useless-escape': 0,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
ignores: ['out/', 'dist/', '**/*.d.ts'],
|
||||||
|
},
|
||||||
|
];
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
# Variables
|
|
||||||
# GITEA_TOKEN="xxxxxxxxxx"
|
|
||||||
# DRONE_TAG="1.1.6"
|
|
||||||
# DRONE_REPO_NAME="vscodestat"
|
|
||||||
# DRONE_REPO_OWNER="root"
|
|
||||||
GITEA_API_URL="https://gitea.raphaelpiccolo.com/api/v1"
|
|
||||||
RELEASE_NAME="Release ${DRONE_TAG}"
|
|
||||||
RELEASE_BODY="vscode extension generated"
|
|
||||||
ARTIFACT_PATH="${DRONE_REPO_NAME}-${DRONE_TAG}.vsix"
|
|
||||||
|
|
||||||
# Create a release
|
|
||||||
response=$(curl -s -X POST "${GITEA_API_URL}/repos/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/releases" \
|
|
||||||
-H "Authorization: token ${GITEA_TOKEN}" \
|
|
||||||
-H "Content-Type: application/json" \
|
|
||||||
-d "{
|
|
||||||
\"tag_name\": \"${DRONE_TAG}\",
|
|
||||||
\"name\": \"${RELEASE_NAME}\",
|
|
||||||
\"body\": \"${RELEASE_BODY}\",
|
|
||||||
\"draft\": false,
|
|
||||||
\"prerelease\": false
|
|
||||||
}")
|
|
||||||
|
|
||||||
# Extract release ID from the response
|
|
||||||
release_id=$(echo $response | jq '.id')
|
|
||||||
|
|
||||||
if [ -z "$release_id" ]; then
|
|
||||||
echo "Failed to create release"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Upload the artifact
|
|
||||||
curl -s -X POST "${GITEA_API_URL}/repos/${DRONE_REPO_OWNER}/${DRONE_REPO_NAME}/releases/${release_id}/assets?name=$(basename ${ARTIFACT_PATH})" \
|
|
||||||
-H "Authorization: token ${GITEA_TOKEN}" \
|
|
||||||
-H "Content-Type: $(file -b --mime-type ${ARTIFACT_PATH})" \
|
|
||||||
--data-binary @"${ARTIFACT_PATH}"
|
|
||||||
|
|
||||||
echo "Artifact uploaded successfully."
|
|
||||||
1765
package-lock.json
generated
1765
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
23
package.json
23
package.json
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "vscodestat",
|
"name": "vscodestat",
|
||||||
"displayName": "vscodestat",
|
"displayName": "vscodestat",
|
||||||
"version": "1.1.10",
|
"version": "1.1.142",
|
||||||
"description": "",
|
"description": "",
|
||||||
"categories": [
|
"categories": [
|
||||||
"Other"
|
"Other"
|
||||||
@@ -12,6 +12,7 @@
|
|||||||
},
|
},
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"author": "Raphael Piccolo",
|
"author": "Raphael Piccolo",
|
||||||
|
"type": "module",
|
||||||
"main": "./out/extension.js",
|
"main": "./out/extension.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"compile": "tsc -p ./",
|
"compile": "tsc -p ./",
|
||||||
@@ -51,18 +52,18 @@
|
|||||||
"onStartupFinished"
|
"onStartupFinished"
|
||||||
],
|
],
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/mocha": "^10.0.7",
|
"@types/mocha": "^10.0.10",
|
||||||
"@types/node": "22.x",
|
"@types/node": "25.x",
|
||||||
"@types/vscode": "^1.92.0",
|
"@types/vscode": "^1.108.1",
|
||||||
"@typescript-eslint/eslint-plugin": "^8.1.0",
|
"@typescript-eslint/eslint-plugin": "^8.54.0",
|
||||||
"@typescript-eslint/parser": "^8.1.0",
|
"@typescript-eslint/parser": "^8.54.0",
|
||||||
"@vscode/test-cli": "^0.0.10",
|
"@vscode/test-cli": "^0.0.12",
|
||||||
"@vscode/test-electron": "^2.4.1",
|
"@vscode/test-electron": "^2.5.2",
|
||||||
"eslint": "^9.9.0",
|
"eslint": "^9.39.2",
|
||||||
"typescript": "^5.5.4"
|
"typescript": "^5.9.3"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"vscode": "^1.92.0"
|
"vscode": "^1.108.1"
|
||||||
},
|
},
|
||||||
"icon": "icon.png",
|
"icon": "icon.png",
|
||||||
"extensionKind": [
|
"extensionKind": [
|
||||||
|
|||||||
@@ -4,13 +4,13 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
console.log('Congratulations, your extension "vscodestat" is now active!');
|
console.log('Congratulations, your extension "vscodestat" is now active!');
|
||||||
|
|
||||||
// crée une commande de test
|
// crée une commande de test
|
||||||
let disposable = vscode.commands.registerCommand('vscodestat.helloWorld', () => {
|
const disposable = vscode.commands.registerCommand('vscodestat.helloWorld', () => {
|
||||||
vscode.window.showInformationMessage('Hello World from vscodestat!');
|
vscode.window.showInformationMessage('Hello World from vscodestat!');
|
||||||
});
|
});
|
||||||
context.subscriptions.push(disposable);
|
context.subscriptions.push(disposable);
|
||||||
|
|
||||||
// commande pour definir l'url
|
// commande pour definir l'url
|
||||||
let disposable2 = vscode.commands.registerCommand('vscodestat.setUrl', async () => {
|
const disposable2 = vscode.commands.registerCommand('vscodestat.setUrl', async () => {
|
||||||
const url = await vscode.window.showInputBox({
|
const url = await vscode.window.showInputBox({
|
||||||
prompt: 'Enter the URL:',
|
prompt: 'Enter the URL:',
|
||||||
placeHolder: ''
|
placeHolder: ''
|
||||||
@@ -24,7 +24,7 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
context.subscriptions.push(disposable2);
|
context.subscriptions.push(disposable2);
|
||||||
|
|
||||||
// commande pour tester l'url
|
// commande pour tester l'url
|
||||||
let disposable3 = vscode.commands.registerCommand('vscodestat.callUrl', async () => {
|
const disposable3 = vscode.commands.registerCommand('vscodestat.callUrl', async () => {
|
||||||
const storedUrl = vscode.workspace.getConfiguration().get('vscodestat.url') as string;
|
const storedUrl = vscode.workspace.getConfiguration().get('vscodestat.url') as string;
|
||||||
if (!storedUrl) {
|
if (!storedUrl) {
|
||||||
vscode.window.showWarningMessage('URL is not set. Please set the URL first.');
|
vscode.window.showWarningMessage('URL is not set. Please set the URL first.');
|
||||||
|
|||||||
Reference in New Issue
Block a user