mirror of
https://github.com/aclindsa/ofxgo.git
synced 2024-11-22 03:30:04 -05:00
cmd/ofx: Add option to use carriage returns for requests
This commit is contained in:
parent
10edd94920
commit
6807c93e0e
@ -22,6 +22,7 @@ func (c *command) usage() {
|
|||||||
// flags common to all server transactions
|
// flags common to all server transactions
|
||||||
var serverURL, username, password, org, fid, appID, appVer, ofxVersion, clientUID string
|
var serverURL, username, password, org, fid, appID, appVer, ofxVersion, clientUID string
|
||||||
var noIndentRequests bool
|
var noIndentRequests bool
|
||||||
|
var carriageReturn bool
|
||||||
|
|
||||||
func defineServerFlags(f *flag.FlagSet) {
|
func defineServerFlags(f *flag.FlagSet) {
|
||||||
f.StringVar(&serverURL, "url", "", "Financial institution's OFX Server URL (see ofxhome.com if you don't know it)")
|
f.StringVar(&serverURL, "url", "", "Financial institution's OFX Server URL (see ofxhome.com if you don't know it)")
|
||||||
@ -34,6 +35,7 @@ func defineServerFlags(f *flag.FlagSet) {
|
|||||||
f.StringVar(&ofxVersion, "ofxversion", "203", "OFX version to use")
|
f.StringVar(&ofxVersion, "ofxversion", "203", "OFX version to use")
|
||||||
f.StringVar(&clientUID, "clientuid", "", "Client UID (only required by a few FIs, like Chase)")
|
f.StringVar(&clientUID, "clientuid", "", "Client UID (only required by a few FIs, like Chase)")
|
||||||
f.BoolVar(&noIndentRequests, "noindent", false, "Don't indent OFX requests")
|
f.BoolVar(&noIndentRequests, "noindent", false, "Don't indent OFX requests")
|
||||||
|
f.BoolVar(&carriageReturn, "carriagereturn", false, "Use carriage return as line separator")
|
||||||
}
|
}
|
||||||
|
|
||||||
func checkServerFlags() bool {
|
func checkServerFlags() bool {
|
||||||
|
@ -18,6 +18,7 @@ func newRequest() (ofxgo.Client, *ofxgo.Request) {
|
|||||||
AppVer: appVer,
|
AppVer: appVer,
|
||||||
SpecVersion: ver,
|
SpecVersion: ver,
|
||||||
NoIndent: noIndentRequests,
|
NoIndent: noIndentRequests,
|
||||||
|
CarriageReturn: carriageReturn,
|
||||||
})
|
})
|
||||||
|
|
||||||
var query ofxgo.Request
|
var query ofxgo.Request
|
||||||
|
Loading…
Reference in New Issue
Block a user