aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/utils/flags.go
diff options
context:
space:
mode:
authorzelig <viktor.tron@gmail.com>2015-10-27 05:24:09 +0800
committerzelig <viktor.tron@gmail.com>2015-10-27 05:24:09 +0800
commit4d005a2c1d2929dc770acd3a2bfed59495c70557 (patch)
tree0442ccefd85cc8b692c2c58a5916bc997909657a /cmd/utils/flags.go
parent3b4ffacd0c63952ceda96b3fafb050c91e72b420 (diff)
downloaddexon-4d005a2c1d2929dc770acd3a2bfed59495c70557.tar.gz
dexon-4d005a2c1d2929dc770acd3a2bfed59495c70557.tar.zst
dexon-4d005a2c1d2929dc770acd3a2bfed59495c70557.zip
rpc api: eth_getNatSpec
* xeth, rpc: implement eth_getNatSpec for tx confirmations * rename silly docserver -> httpclient * eth/backend: httpclient now accessible via eth.Ethereum init-d via config.DocRoot * cmd: introduce separate CLI flag for DocRoot (defaults to homedir) * common/path: delete unused assetpath func, separate HomeDir func
Diffstat (limited to 'cmd/utils/flags.go')
-rw-r--r--cmd/utils/flags.go10
1 files changed, 8 insertions, 2 deletions
diff --git a/cmd/utils/flags.go b/cmd/utils/flags.go
index 66ec46f80..79c86c52a 100644
--- a/cmd/utils/flags.go
+++ b/cmd/utils/flags.go
@@ -139,6 +139,11 @@ var (
Name: "natspec",
Usage: "Enable NatSpec confirmation notice",
}
+ DocRootFlag = DirectoryFlag{
+ Name: "docroot",
+ Usage: "Document Root for HTTPClient file scheme",
+ Value: DirectoryString{common.HomeDir()},
+ }
CacheFlag = cli.IntFlag{
Name: "cache",
Usage: "Megabytes of memory allocated to internal caching",
@@ -452,6 +457,7 @@ func MakeEthConfig(clientID, version string, ctx *cli.Context) *eth.Config {
Olympic: ctx.GlobalBool(OlympicFlag.Name),
NAT: MakeNAT(ctx),
NatSpec: ctx.GlobalBool(NatspecEnabledFlag.Name),
+ DocRoot: ctx.GlobalString(DocRootFlag.Name),
Discovery: !ctx.GlobalBool(NoDiscoverFlag.Name),
NodeKey: MakeNodeKey(ctx),
Shh: ctx.GlobalBool(WhisperEnabledFlag.Name),
@@ -616,7 +622,7 @@ func StartIPC(eth *eth.Ethereum, ctx *cli.Context) error {
xeth := xeth.New(eth, fe)
codec := codec.JSON
- apis, err := api.ParseApiString(ctx.GlobalString(IPCApiFlag.Name), codec, xeth, eth, ctx.GlobalString(JSpathFlag.Name))
+ apis, err := api.ParseApiString(ctx.GlobalString(IPCApiFlag.Name), codec, xeth, eth)
if err != nil {
return nil, err
}
@@ -637,7 +643,7 @@ func StartRPC(eth *eth.Ethereum, ctx *cli.Context) error {
xeth := xeth.New(eth, nil)
codec := codec.JSON
- apis, err := api.ParseApiString(ctx.GlobalString(RpcApiFlag.Name), codec, xeth, eth, ctx.GlobalString(JSpathFlag.Name))
+ apis, err := api.ParseApiString(ctx.GlobalString(RpcApiFlag.Name), codec, xeth, eth)
if err != nil {
return err
}