-
Notifications
You must be signed in to change notification settings - Fork 134
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
Persistent history #30
Comments
I totally agree this should be added to Vantage. I also think it should be built-in native, not as an extension. There are a ton of ways to do it, which makes me uneasy. It should be done exactly the way Linux/SSH sessions handle persistent command history, so there is consistency - it should behave exactly the way people are used to it behaving. I'll have to find out how it's done (i.e. when SSHing to another terminal, the commands are persisted locally, etc., as well as what primary keys are used to match up users and terminals to a given history, etc.). If there's any way you could help do research on that, it would definitely help speed up the implementation! |
In other words, you could say history is stored remotely, on a per-user basis, in a plain file.
For example, I can picture this kind of interface: vantage.history(".vantage-history") // current directory storage, shared
vantage.history(".vantage/<user>-history") // current directory, per-user
vantage.history("/vantage/<app>/<user>-history") // system-wide, per-app + per-user I could spare some free time to implement this and submit a pull request. If you're short on time, let me know and give me a few days =) |
Nice and thanks for the data - I didn't know those things. Your idea sounds right. On unauthenticated access, I think I assign a user account as I'm very short on time, so it would be totally awesome if you could spare time to do this! I should probably fill you in on some more details as to how Vantage handles sessions, etc. as getting this working is going to require modifications across the code base, particularly adding content to: ./lib/vantage.js
./lib/client.js
./lib/server.js Feel free to ask me any questions or confusions - don't hesitate at all! In regards interface, I think we should go with Convention over Configuration and not try to expose it that publicly to users, unless they really need to change it. It should just work as a default, I think. |
@slezica does it look like you're going to be able to work on this? |
@dthree I'm sorry for the dissapearance. I switched jobs, working both during the transition, and have been unable to spare time for any of my personal projects. I'd love to contribute this feature (I use I hope I can come back and contribute some solid code to this project in the future. |
No probs and thanks for letting me know. |
Command history is handy, but it doesn't live beyond a session. It would be awesome if
vantage
had persistent history. As of now, this can only be achieved by loading entries intovagrant.session._hist
.History could be kept server-side on a per-user basis, or client-side on a per-host basis.
For a server-side implementation, instead of bundling this functionality with
vantage
itself, a public history API could be exposed for extensions to manage and provide history, with session history as the default implementation.A client-side implementation could provide a
vantage
command-line flag to pick a history file, defaulting to something like~/.vantage/history/<host>
(for system-wide, per-host history) or./vantage/history
(for directory-based history).The text was updated successfully, but these errors were encountered: