Skip to content

Allow commented out "-name" lines.#169

Closed
jamesproud wants to merge 1 commit intobasho:masterfrom
jamesproud:patch-1
Closed

Allow commented out "-name" lines.#169
jamesproud wants to merge 1 commit intobasho:masterfrom
jamesproud:patch-1

Conversation

@jamesproud
Copy link
Copy Markdown

Example vm.args:

-name riak@127.0.0.1

-name riak@127.0.0.2

riak-admin concatenates the above as "#-name riak@127.0.0.1 -name riak@127.0.0.2" currently.

@n00k
Copy link
Copy Markdown

n00k commented Jun 20, 2012

shouldn't the regex be '^-[s]*name', so it will match
-name riak@node.host
but not a commented name like
#-name test-riak@node.hode
or a comment about the switch like
#use the -name switch to specify the name of the node
or another switch that happens to contain that like
-administrator-name admin

@ghost ghost assigned bookshelfdave Jun 22, 2012
@seancribbs
Copy link
Copy Markdown
Contributor

Also note that [s]*name is wrong and should be s?name. Erlang will ignore a switch like -sssssssssname. I vote for grep "^[[:space:]]*-s\?name"

@bookshelfdave
Copy link
Copy Markdown
Contributor

I tested all cases mentioned above on OSX and the regex grep "^[[:space:]]*-s\?name" works. We'll need to test on other platforms as well.

bookshelfdave pushed a commit that referenced this pull request Jun 25, 2012
@bookshelfdave
Copy link
Copy Markdown
Contributor

Tested on OSX, Ubuntu 12.04 x64, FreeBSD 9 x64

@ghost ghost assigned jaredmorrow Jun 26, 2012
@bookshelfdave
Copy link
Copy Markdown
Contributor

My apologies, I recreated this fix in branch dip_gh169 as I was unsure about my rebase/squash.

Please see #175

@ghost ghost self-assigned this Jun 27, 2012
hmmr pushed a commit that referenced this pull request Nov 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants