Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fabiospampinato/autogit-plugin-rollback
A plugin for rolling back the history to that of the origin and discarding local changes.
https://github.com/fabiospampinato/autogit-plugin-rollback
autogit plugin reset revert rollback
Last synced: about 1 month ago
JSON representation
A plugin for rolling back the history to that of the origin and discarding local changes.
- Host: GitHub
- URL: https://github.com/fabiospampinato/autogit-plugin-rollback
- Owner: fabiospampinato
- License: mit
- Archived: true
- Created: 2018-10-17T19:09:06.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-01-24T20:28:23.000Z (over 4 years ago)
- Last Synced: 2024-07-24T18:22:39.827Z (about 2 months ago)
- Topics: autogit, plugin, reset, revert, rollback
- Language: TypeScript
- Size: 19.5 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Autogit Plugin - Rollback
A plugin for rolling back the history to that of the origin and discarding local changes.
This plugin is quite useful when developing other plugins or commands. You can test them, and if they don't work properly you can just roll back.
## Install
```sh
npm install --save autogit-plugin-rollback
```## Usage
#### Options
This plugin uses the following options object:
```js
{
remote: 'origin', // Resetting history up to the last commit present in this remote
rollback: { // Things to roll back
workingTree: true, // Discard all local changes
history: true // Discard all new commits compared to the remote
},
force: false // Don't ask for confirmation
}
```#### Configuration
Add this plugin to a command:
```js
const rollback = require ( 'autogit-plugin-rollback' );module.exports = {
commands: {
'my-command': [
rollback ({
rollback: {
workingTree: true
history: false
}
})
]
}
}
```## License
MIT © Fabio Spampinato