Conversation
* Added `cmd.versionCmd`, replacing the `version` flag * Added `cmd.updateSettings` to set flags once parsing has occurred during execution * Added extra debug information
* Added `cmd.printCmd` * Added `cmd.printConnection` that works in a similar fashion to `cmd.showConnection`, but print the command instead of the entry for a config
* Updated config.Settings and config.GetConfig to store EnvSSHDefaultUsername, EnvSSHIdentityFile, and EnvSSHUsername * Removed EnvSSHUsername and EnvSSHIdentityFile from cmd
* Updated ssh.generateUserName to bypass templated names * Fixed issue of template referencing * Updated ssh.Placeholders to add @@USER_FIRSTNAME.@@USER_LASTNAME and cfg.EnvSSHUsername * Fixed issue with templates due to input for tempUser.generateUserName and tempUser.rewriteUsername
* Added cmd.deleteCmd * Added cmd.deleteConnection, which first of all checks to see if the connection exists before attempting to remove it
* Added vault.secretData map * Updated vault.WriteSecret to normalise the options passed in by the user, e.g. hostname -> HostName
* Added cmd.writeCmd * Added cmd.writeConnection, which will currently refuse to write to an existing entry until the partial update logic is added * Added ConfigComment to config.Settings * Added --comment flag for use with writeCmd
* Added --dry-run * Added output for cmd.writeCmd and cmd.deleteCmd when using Simulate
* Fixed issue where an empty/misconfigured EnvSSHUsername produces an empty (@@) placeholder, causing other placeholders to be modified during the rewrite * Added comment before ssh.EnvSSHDefaultUsername to note how to override during build
* Added caching mechanism:
* `cmd.CacheExpireAfter` controls the expiry threshold, default 7 days
* `cmd.getCachePath()` generates the path to use for a connection
* `cmd.makeCachePath()` creates the storage directory
* `cmd.getRemoteCache()` generates a cache file from the remote data
* `cmd.saveCache()` writes JSON data to disk as a cache
* `cmd.getCache()` reads JSON data from disk to save a look-up from live
* `cmd.removeCache()` removes a single cached connection
* `cmd.expireCache()` removes a single cached connection when the expiry
threshold has been exceeded
* `cmd.purgeCache()` wipes out the local cache storage, since it is possible
to use `--storage-path` with this, care should be taken with its use.
This will be improved in the near future
* Added unittests for caching, `cmd.TestCache()`
* Added `cmd.connectCmd` and `cmd.purgeCmd`
This was referenced May 6, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Some issues were hit with the original code structure and so we have a considerable rewrite to solve those and hopefully avoid similar ones in the future.
Unit tests have been added for the majority of functionality