Skip to content

Commit 9c00206

Browse files
Add Copilot and JavaScript style guidelines
1 parent 4ff4ce3 commit 9c00206

File tree

4 files changed

+56
-2
lines changed

4 files changed

+56
-2
lines changed

.github/commit-styles.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Commit Styles
2+
3+
## Coding Standards
4+
5+
- Ensure very short messages.
6+
- When the message is for the release branch, prefix the message with 'Release v'.

.github/copilot-instructions.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Copilot Instructions
2+
3+
This project is a set of Cloud Run applications that allows to run different
4+
pipelines, extracting data and analyzing them with R framework.
5+
6+
## Model Tone
7+
8+
- If I tell you that you are wrong, think about whether or not you think that's true and respond with facts.
9+
- Avoid apologizing or making conciliatory statements.
10+
- It is not necessary to agree with the user with statements such as "You're right" or "Yes".
11+
- Avoid hyperbole and excitement, stick to the task at hand and complete it pragmatically.

.github/js-styles.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Javascript Styles
2+
3+
## Coding Standards
4+
5+
- Use camelCase for variable and function names.
6+
- Use function declaration for new functions.
7+
- Use PascalCase for component names.
8+
- Use double quotes for strings.
9+
- Use 4 spaces for indentation.
10+
- Use arrow functions for callbacks.
11+
- Use async/await for asynchronous code.
12+
- Use const for constants and let for variables that will be reassigned.
13+
- Add a blank line after a single const declaration.
14+
- Add a blank line after a block of const declarations.
15+
- Do not add blank lines between consecutive const declarations in the same block.
16+
- Use destructuring for objects and arrays.
17+
- Use template literals for strings that contain variables.
18+
- Use the latest JavaScript features (ES6+) where possible.
19+
- Use space between operator.
20+
21+
## ESLint Configuration
22+
23+
- Use the ESLint configuration defined in `eslint.config.js` at the project root
24+
- Run ESLint before committing changes: `npm test`.

.vscode/settings.json

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,18 @@
11
{
22
"files.exclude": {
3-
"node_modules": true
4-
}
3+
"**/node_modules": true
4+
},
5+
"search.exclude": {
6+
"**/node_modules": true
7+
},
8+
"github.copilot.chat.codeGeneration.instructions": [
9+
{
10+
"file": "./.github/js-styles.md"
11+
}
12+
],
13+
"github.copilot.chat.commitMessageGeneration.instructions": [
14+
{
15+
"file": "./.github/commit-styles.md"
16+
}
17+
]
518
}

0 commit comments

Comments
 (0)