0.1.3 Update git commands and fix commit
This commit is contained in:
parent
d61c2fedfc
commit
b32efb5b17
2 changed files with 27 additions and 16 deletions
29
CHANGELOG.md
29
CHANGELOG.md
|
|
@ -2,27 +2,36 @@
|
|||
|
||||
All notable changes to the "dwm-git-simpleuse" extension will be documented in this file.
|
||||
|
||||
## [Unreleased]
|
||||
## [Unreleased] <span style="font-size:0.5em;">_(not in order)_</span>
|
||||
|
||||
- Task API
|
||||
- no git warnings as errors
|
||||
- progress bar for git commands
|
||||
- No git msgs as errors
|
||||
- check if in git repository before running commands
|
||||
- Progress bar for git commands
|
||||
- Upload only active file
|
||||
- Make it possible to receive a webhook to send info to user
|
||||
|
||||
## [0.1.3] - 2024-07-18
|
||||
|
||||
- Fixed "commit message auto increment"
|
||||
- Fixed commit message couldn't have `'` in it
|
||||
- added "--ff" to git pull
|
||||
|
||||
## [0.1.2] - 2024-07-11
|
||||
|
||||
- fixed "initialize existing repository" command
|
||||
- renamed commands with "gitDWM : " prefix
|
||||
- Fixed "initialize existing repository" command
|
||||
- Renamed commands with "gitDWM : " prefix
|
||||
|
||||
## [0.1.0] - 2024-04-10
|
||||
|
||||
- choose commmit message
|
||||
- commit message auto increment
|
||||
- command to initialize existing repository
|
||||
- activation event set to "onStartupFinished"
|
||||
- Choose commmit message
|
||||
- Commit message auto increment
|
||||
- Command to initialize existing repository
|
||||
- Activation event set to "onStartupFinished"
|
||||
|
||||
## [0.0.2] - 2024-02-02
|
||||
|
||||
- renamed command to something else than "helloworld" => ("full push")
|
||||
- Renamed command to something else than "helloworld" => ("full push")
|
||||
|
||||
## [0.0.1] - 2024-02-01
|
||||
|
||||
|
|
|
|||
12
extension.js
12
extension.js
|
|
@ -49,7 +49,7 @@ function activate(context) {
|
|||
lastGitCommitMsg = gitCommitMsg;
|
||||
|
||||
chp.exec(
|
||||
`git add . && git commit -am '${gitCommitMsg}' && git pull && git push`,
|
||||
`git add . && git commit -am "${gitCommitMsg.replace(/"/g, '\\"')}" && git pull --ff && git push`,
|
||||
{ cwd: vscode.workspace.workspaceFolders[0].uri.fsPath },
|
||||
(err, stdout, stderr) => {
|
||||
if (err) {
|
||||
|
|
@ -147,8 +147,10 @@ module.exports = {
|
|||
};
|
||||
|
||||
String.prototype.incrementSuffixe = function () {
|
||||
if (this == "") return "";
|
||||
return this.replace(/(\d+)?$/, function (match, p1) {
|
||||
return p1 === undefined ? "(1)" : `(${parseInt(p1) + 1})`;
|
||||
});
|
||||
const match = this.match(/\s*\((\d+)\)\s*$/);
|
||||
return match
|
||||
? this.replace(match[0], ` (${+match[1] + 1})`)
|
||||
: this.trim().length
|
||||
? this + " (1)"
|
||||
: this.trim();
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue