Closed piotrnar closed 3 months ago
This still needs to be addressed.
A preferred solution is to use a temporary folder for the files needed to sign a transaction - either in the gateway's sub-folder or somewhere within the path returned by os.TempDir() Also would be nice to clean the files after the signing is done.
For the wallet's binary, there should be no need to configure any paths. There will only be a requirement that the wallet binary must be placed within OS'es PATH.
Also mind that Windows uses wallet.exe as the binary name and the default path separator character is different there. A neat solution would be to use "os.PathSeparator" (from golang os package) for building the paths.
By default, if the -wallet
flag is not provided, then gateway
program creates a temporary folder named wallet
in the current working directory and uses that. The temporary folder will be deleted when the program terminates.
good
Get rid of the TempWalletFolderPath so we don't have to modify it each time after pulling the sources before building. Maybe just assume that the wallet's executable will be placed in the current folder. Or add a simple config file where the user can setup these values (as well as e.g. the client's ip:port). Choose whatever method you like, but the fixed paths and addresses have to be removed from the source code, for obvious reasons.