mirror of
https://github.com/OneUptime/oneuptime
synced 2024-11-21 14:49:07 +00:00
chore: Remove unused configuration files and scripts
This commit is contained in:
parent
2862d1e69b
commit
dd336896d2
15
.oneuptime/README.md
Normal file
15
.oneuptime/README.md
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
## OneUptime Copilot
|
||||||
|
|
||||||
|
This folder contains the configuration files for the OneUptime Copilot. The Copilot is a tool that automatically improves your code. It can fix issues, improve code quality, and help you ship faster.
|
||||||
|
|
||||||
|
This folder has the following structure:
|
||||||
|
|
||||||
|
- `config.js`: The configuration file for the Copilot. You can customize the Copilot's behavior by changing this file.
|
||||||
|
- `scripts`: A folder containing scripts that the Copilot runs. These are hooks that run at different stages of the Copilot's process.
|
||||||
|
- `on-after-clone.sh`: A script that runs after the Copilot clones your repository.
|
||||||
|
- `on-before-code-change.sh`: A script that runs before the Copilot makes changes to your code.
|
||||||
|
- `on-after-code-change.sh`: A script that runs after the Copilot makes changes to your code.
|
||||||
|
- `on-before-commit.sh`: A script that runs before the Copilot commits changes to your repository.
|
||||||
|
- `on-after-commit.sh`: A script that runs after the Copilot commits changes to your repository.
|
||||||
|
|
||||||
|
|
10
.oneuptime/config.js
Normal file
10
.oneuptime/config.js
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
// This is the configuration file for the oneuptime copilot.
|
||||||
|
|
||||||
|
const getCopilotConfig = () => {
|
||||||
|
return {
|
||||||
|
// The version of the schema for this configuration file.
|
||||||
|
schemaVersion: '1.0',
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default getCopilotConfig;
|
@ -1,3 +0,0 @@
|
|||||||
{
|
|
||||||
|
|
||||||
}
|
|
@ -1,2 +1,16 @@
|
|||||||
|
# Description: Copilot clones your repository and to improve your code.
|
||||||
|
# This scirpt runs after the clone process is completed.
|
||||||
|
# Some of the common tasks you can do here are:
|
||||||
|
# 1. Install dependencies
|
||||||
|
# 2. Run linting
|
||||||
|
# 3. Run tests
|
||||||
|
# 4. Run build
|
||||||
|
# 5. Run any other command that you want to run after the clone process is completed.
|
||||||
|
# If this script fails, copilot will not proceed with the next steps to improve your code.
|
||||||
|
# This step is to ensure that the code is in a good state before we start improving it.
|
||||||
|
# If you want to skip this script, you can keep this file empty.
|
||||||
|
# It's highly recommended to run linting and tests in this script to ensure the code is in a good state.
|
||||||
|
# This scirpt will run on ubuntu machine. So, make sure the commands you run are compatible with ubuntu.
|
||||||
|
|
||||||
npm install
|
npm install
|
||||||
npm run lint
|
npm run lint
|
13
.oneuptime/scripts/on-after-code-change.sh
Normal file
13
.oneuptime/scripts/on-after-code-change.sh
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
# Description: Copilot will run this script after we make improvements to your code and write it to disk.
|
||||||
|
# Some of the common tasks you can do here are:
|
||||||
|
# 1. Run linting
|
||||||
|
# 2. Run tests
|
||||||
|
# 3. Run build
|
||||||
|
# 4. Run any other command that you want to run after the code is changed.
|
||||||
|
# If this script fails, copilot will not commit the changes to your repository.
|
||||||
|
# This step is to ensure that the code is in a good state before we commit the changes.
|
||||||
|
# If you want to skip this script, you can keep this file empty.
|
||||||
|
# It's highly recommended to run linting and tests in this script to ensure the code is in a good state.
|
||||||
|
# This scirpt will run on ubuntu machine. So, make sure the commands you run are compatible with ubuntu.
|
||||||
|
|
||||||
|
npm run fix
|
@ -1 +1 @@
|
|||||||
|
# Description: Copilot will run this script after the commit process is completed.
|
@ -1 +0,0 @@
|
|||||||
npm run fix
|
|
9
.oneuptime/scripts/on-before-code-change.sh
Normal file
9
.oneuptime/scripts/on-before-code-change.sh
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
# Description: Copilot will run this script before we make changes to your code.
|
||||||
|
# Some of the common tasks you can do here are:
|
||||||
|
# 1. Install dependencies
|
||||||
|
# 2. Run any other command that you want to run before the code is changed.
|
||||||
|
# If this script fails, copilot will not make any changes to the code.
|
||||||
|
# This step is to ensure that the code is in a good state before we start making changes.
|
||||||
|
# If you want to skip this script, you can keep this file empty.
|
||||||
|
# It's highly recommended to run things like installing dependencies in this script.
|
||||||
|
# This scirpt will run on ubuntu machine. So, make sure the commands you run are compatible with ubuntu.
|
@ -0,0 +1 @@
|
|||||||
|
# Description: Copilot will run this script before we commit the changes to your repository.
|
@ -1,3 +0,0 @@
|
|||||||
{
|
|
||||||
|
|
||||||
}
|
|
@ -143,7 +143,7 @@ If you have any feedback or suggestions, please let us know. We would love to h
|
|||||||
|
|
||||||
const onBeforeExecuteActionScript: string | null =
|
const onBeforeExecuteActionScript: string | null =
|
||||||
await CodeRepositoryUtil.getRepoScript({
|
await CodeRepositoryUtil.getRepoScript({
|
||||||
scriptType: RepoScriptType.OnBeforeCopilotAction,
|
scriptType: RepoScriptType.OnBeforeCodeChange,
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!onBeforeExecuteActionScript) {
|
if (!onBeforeExecuteActionScript) {
|
||||||
@ -192,7 +192,7 @@ If you have any feedback or suggestions, please let us know. We would love to h
|
|||||||
|
|
||||||
const onAfterExecuteActionScript: string | null =
|
const onAfterExecuteActionScript: string | null =
|
||||||
await CodeRepositoryUtil.getRepoScript({
|
await CodeRepositoryUtil.getRepoScript({
|
||||||
scriptType: RepoScriptType.OnAfterCopilotAction,
|
scriptType: RepoScriptType.OnAfterCodeChange,
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!onAfterExecuteActionScript) {
|
if (!onAfterExecuteActionScript) {
|
||||||
|
15
Copilot/Templates/.oneuptime/README.md
Normal file
15
Copilot/Templates/.oneuptime/README.md
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
## OneUptime Copilot
|
||||||
|
|
||||||
|
This folder contains the configuration files for the OneUptime Copilot. The Copilot is a tool that automatically improves your code. It can fix issues, improve code quality, and help you ship faster.
|
||||||
|
|
||||||
|
This folder has the following structure:
|
||||||
|
|
||||||
|
- `config.js`: The configuration file for the Copilot. You can customize the Copilot's behavior by changing this file.
|
||||||
|
- `scripts`: A folder containing scripts that the Copilot runs. These are hooks that run at different stages of the Copilot's process.
|
||||||
|
- `on-after-clone.sh`: A script that runs after the Copilot clones your repository.
|
||||||
|
- `on-before-code-change.sh`: A script that runs before the Copilot makes changes to your code.
|
||||||
|
- `on-after-code-change.sh`: A script that runs after the Copilot makes changes to your code.
|
||||||
|
- `on-before-commit.sh`: A script that runs before the Copilot commits changes to your repository.
|
||||||
|
- `on-after-commit.sh`: A script that runs after the Copilot commits changes to your repository.
|
||||||
|
|
||||||
|
|
10
Copilot/Templates/.oneuptime/config.js
Normal file
10
Copilot/Templates/.oneuptime/config.js
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
// This is the configuration file for the oneuptime copilot.
|
||||||
|
|
||||||
|
const getCopilotConfig = () => {
|
||||||
|
return {
|
||||||
|
// The version of the schema for this configuration file.
|
||||||
|
schemaVersion: '1.0',
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default getCopilotConfig;
|
13
Copilot/Templates/.oneuptime/scripts/on-after-clone.sh
Normal file
13
Copilot/Templates/.oneuptime/scripts/on-after-clone.sh
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
# Description: Copilot clones your repository and to improve your code.
|
||||||
|
# This scirpt runs after the clone process is completed.
|
||||||
|
# Some of the common tasks you can do here are:
|
||||||
|
# 1. Install dependencies
|
||||||
|
# 2. Run linting
|
||||||
|
# 3. Run tests
|
||||||
|
# 4. Run build
|
||||||
|
# 5. Run any other command that you want to run after the clone process is completed.
|
||||||
|
# If this script fails, copilot will not proceed with the next steps to improve your code.
|
||||||
|
# This step is to ensure that the code is in a good state before we start improving it.
|
||||||
|
# If you want to skip this script, you can keep this file empty.
|
||||||
|
# It's highly recommended to run linting and tests in this script to ensure the code is in a good state.
|
||||||
|
# This scirpt will run on ubuntu machine. So, make sure the commands you run are compatible with ubuntu.
|
11
Copilot/Templates/.oneuptime/scripts/on-after-code-change.sh
Normal file
11
Copilot/Templates/.oneuptime/scripts/on-after-code-change.sh
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Description: Copilot will run this script after we make improvements to your code and write it to disk.
|
||||||
|
# Some of the common tasks you can do here are:
|
||||||
|
# 1. Run linting
|
||||||
|
# 2. Run tests
|
||||||
|
# 3. Run build
|
||||||
|
# 4. Run any other command that you want to run after the code is changed.
|
||||||
|
# If this script fails, copilot will not commit the changes to your repository.
|
||||||
|
# This step is to ensure that the code is in a good state before we commit the changes.
|
||||||
|
# If you want to skip this script, you can keep this file empty.
|
||||||
|
# It's highly recommended to run linting and tests in this script to ensure the code is in a good state.
|
||||||
|
# This scirpt will run on ubuntu machine. So, make sure the commands you run are compatible with ubuntu.
|
1
Copilot/Templates/.oneuptime/scripts/on-after-commit.sh
Normal file
1
Copilot/Templates/.oneuptime/scripts/on-after-commit.sh
Normal file
@ -0,0 +1 @@
|
|||||||
|
# Description: Copilot will run this script after the commit process is completed.
|
@ -0,0 +1,9 @@
|
|||||||
|
# Description: Copilot will run this script before we make changes to your code.
|
||||||
|
# Some of the common tasks you can do here are:
|
||||||
|
# 1. Install dependencies
|
||||||
|
# 2. Run any other command that you want to run before the code is changed.
|
||||||
|
# If this script fails, copilot will not make any changes to the code.
|
||||||
|
# This step is to ensure that the code is in a good state before we start making changes.
|
||||||
|
# If you want to skip this script, you can keep this file empty.
|
||||||
|
# It's highly recommended to run things like installing dependencies in this script.
|
||||||
|
# This scirpt will run on ubuntu machine. So, make sure the commands you run are compatible with ubuntu.
|
1
Copilot/Templates/.oneuptime/scripts/on-before-commit.sh
Normal file
1
Copilot/Templates/.oneuptime/scripts/on-before-commit.sh
Normal file
@ -0,0 +1 @@
|
|||||||
|
# Description: Copilot will run this script before we commit the changes to your repository.
|
@ -39,8 +39,8 @@ export enum RepoScriptType {
|
|||||||
OnAfterClone = "onAfterClone",
|
OnAfterClone = "onAfterClone",
|
||||||
OnBeforeCommit = "onBeforeCommit",
|
OnBeforeCommit = "onBeforeCommit",
|
||||||
OnAfterCommit = "OnAfterCommit",
|
OnAfterCommit = "OnAfterCommit",
|
||||||
OnBeforeCopilotAction = "onBeforeCopilotAction",
|
OnBeforeCodeChange = "OnBeforeCodeChange",
|
||||||
OnAfterCopilotAction = "onAfterCopilotAction",
|
OnAfterCodeChange = "OnAfterCodeChange",
|
||||||
}
|
}
|
||||||
|
|
||||||
export default class CodeRepositoryUtil {
|
export default class CodeRepositoryUtil {
|
||||||
|
Loading…
Reference in New Issue
Block a user