Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prerelease/parser #4

Open
wants to merge 18 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions dist/gitlabator-plugin.js

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions dist/gitlabator-plugin.js.LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/*! Browser bundle of nunjucks 3.2.4 */

/*! For license information please see leto-modelizer-plugin-core.js.LICENSE.txt */
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ module.exports = {
transform: {
'^.+\\.(js|jsx)?$': 'babel-jest',
},
transformIgnorePatterns: ['<rootDir>/node_modules/(?!antlr)'],
transformIgnorePatterns: ['<rootDir>/node_modules/(?!lidy)'],
testResultsProcessor: 'jest-sonar-reporter',
collectCoverage: true,
collectCoverageFrom: ['src/**/*.js'],
Expand Down
4 changes: 2 additions & 2 deletions jsdoc.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@
"monospaceLinks": false,
"search": true,
"better-docs": {
"name": "terrator-plugin",
"name": "gitlabator-plugin",
"css": "style.css",
"trackingCode": "tracking-code-which-will-go-to-the-HEAD",
"hideGenerator": false,
"navLinks": [
{
"label": "Github",
"href": "https://github.com/ditrit/terrator-plugin#README.md"
"href": "https://github.com/kaiedhazem/gitlabator-plugin.git"
}
]
}
Expand Down
11,444 changes: 1,433 additions & 10,011 deletions package-lock.json

Large diffs are not rendered by default.

62 changes: 33 additions & 29 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,55 +1,59 @@
{
"name": "gitlabator-plugin",
"version": "0.1.0",
"description": "Gitlab plugin for Leto-Modelizer.",
"description": "gitlab-plugin for leto-modelizer",
"main": "dist/gitlabator-plugin.js",
"exports": "./dist/gitlabator-plugin.js",
"scripts": {
"build": "webpack",
"build:docs": "jsdoc --readme README.md --package package.json -r ./src/ -c jsdoc.config.json -d docs",
"lint": "eslint --max-warnings=0 --ext .js src",
"lint:fix": "eslint --max-warnings=0 --fix --ext .js src",
"lint:report": "eslint --max-warnings=0 --ext .js src -f json-relative > eslint.json",
"lint": "eslint --ext .js src",
"lint:fix": "eslint --fix --ext .js src",
"lint:report": "eslint --ext .js src -f json-relative > eslint.json",
"prepare:docs": "sed -i 's#taffydb#@jsdoc/salty#g' node_modules/better-docs/publish.js",
"test": "jest",
"test:coverage": "jest --coverage"
},
"repository": {
"type": "git",
"url": "git+https://github.com/ditrit/gitlabator-plugin.git"
"url": "git+https://github.com/kaiedhazem/gitlabator-plugin.git"
},
"keywords": [
"Leto-modelizer",
"gitlabator-plugin",
"gitlab"
"gitlabator-plugin"
],
"author": "Vincent Moittie <moittie.vincent@gmail.com>",
"author": "Kaied Hazem <gaiedhazem@gmail.com>",
"license": "Mozilla Public License 2.0",
"bugs": {
"url": "https://github.com/ditrit/gitlabator-plugin/issues"
"url": "https://github.com/kaiedhazem/gitlabator-plugin.git/issues"
},
"homepage": "https://github.com/ditrit/gitlabator-plugin#readme",
"homepage": "https://github.com/kaiedhazem/gitlabator-plugin.git#readme",
"dependencies": {
"leto-modelizer-plugin-core": "github:ditrit/leto-modelizer-plugin-core#0.17.0"
"leto-modelizer-plugin-core": "github:ditrit/leto-modelizer-plugin-core#0.21.0",
"lidy-js": "github:ditrit/lidy-js#1.0.1",
"nunjucks": "=3.2.4"
},
"devDependencies": {
"@babel/core": "=7.22.9",
"@babel/preset-env": "=7.22.9",
"babel-jest": "=29.6.1",
"babel-loader": "=9.1.3",
"better-docs": "=2.7.2",
"eslint": "=8.45.0",
"eslint-config-airbnb-base": "=15.0.0",
"eslint-formatter-json-relative": "=0.1.0",
"eslint-plugin-import": "=2.27.5",
"eslint-plugin-jest": "=27.2.3",
"eslint-plugin-jsdoc": "=46.4.4",
"eslint-webpack-plugin": "=4.0.1",
"jest": "=29.6.1",
"jest-environment-jsdom": "=29.6.1",
"jest-sonar-reporter": "=2.0.0",
"jsdoc": "=4.0.2",
"webpack": "=5.88.1",
"webpack-cli": "=5.1.4"
"@babel/core": "^7.23.2",
"@babel/preset-env": "^7.23.2",
"babel-jest": "^29.7.0",
"babel-loader": "^9.1.3",
"better-docs": "^2.7.2",
"eslint": "^8.51.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-formatter-json-relative": "^0.1.0",
"eslint-plugin-import": "^2.28.1",
"eslint-plugin-jest": "^27.4.2",
"eslint-plugin-jsdoc": "^44.2.7",
"eslint-webpack-plugin": "^4.0.1",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"jest-sonar-reporter": "^2.0.0",
"js-yaml": "^4.1.0",
"jsdoc": "^4.0.2",
"leto-modelizer-plugin-core": "github:ditrit/leto-modelizer-plugin-core#0.21.0",
"lidy-js": "github:ditrit/lidy-js#main",
"webpack": "^5.89.0",
"webpack-cli": "^5.1.4"
}
}
1 change: 1 addition & 0 deletions public/icons/DefaultGitlabCi.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions public/icons/DefaultJobCi.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions public/icons/DefaultService.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 50 additions & 0 deletions public/models/gitlabCi.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
72 changes: 72 additions & 0 deletions public/models/jobCi.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
72 changes: 72 additions & 0 deletions public/models/service.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions scripts/generate_parser.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
const fs = require('fs');

import('lidy-js/parser/node_parse.js').then(({ preprocess }) => {
preprocess('../src/lidy/gitlab.yml');
}).then(() => {
return new Promise((resolve) => {
fs.readFile('../src/lidy/gitlab.js', 'utf8', (err, data) => {
resolve(data);
});
});
}).then((data) => {
fs.writeFile(
'../src/lidy/gitlab.js',
data.replace("from '../parser/parse.js'", "from 'lidy-js'"),
() => {}
);
});
Loading