Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
i needed to pass some arguments to a exe, but one of the argument was having a space
the code is
myApp.exe arg1 arg 2
This created a problem as the second argument was split into two.The work around i did was like
myApp.exe arg1 'arg 2'
this helped in passing argument with space as a single argument
Enclose them in double quotes:
myApp.exe arg1 "arg 2"
Related
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 10 days ago.
The community is reviewing whether to reopen this question as of 10 days ago.
Improve this question
I want to do something like $foo | .\bar.ps1, and handle $foo inside bar.ps1. What's the minimal example of bar.ps1 in which I can access the value of $foo?
Edit:
The question has been closed, but I have found the answer: write in the file as if it's a function, but just strip function {} keyword, just put what you would put inside the {}. If you don't have a process{} block, use $input to access the piped value. If you have a process{} block, use $PSItem.
It's worth noting that $input can only be accessed once, so save it to a variable first.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
In emacs, is there a way to make rgrep default to searching the last term that was passed to it rather than the word at point? I almost always want to do the former rather than the latter. I looked at the help for rgrep, but it was silent on this point.
If you pick through the source code, you find that you can get what you want by setting the variable find-tag-default-function. You could also redefine the function grep-tag-default, or associate a property with the major mode via put. Here's a solution that sets the variable:
(setq find-tag-default-function 'last-grep-tag)
(defun last-grep-tag ()
(if grep-regexp-history
(car grep-regexp-history)
""))
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I have long column of words
Rolls Royce
Volkswagen
Aston Martin
Audi
BMW
Mercedes-Benz
Porsche
Bentley
How to make these words comma separated like ...BMW,Audi...
Use find and replace with the following inputs:
find: ^p
replace: ,
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
If I add a daemon to rc.conf, how can I then pass arguments to it?
Eg
DAEMONS = (sshd mongodb ...)
How can I pass --replSet to the mongodb daemon?
You should try to set this behaviour in /etc/mongodb.conf
I don't think you pass anything, it calls the daemon from /etc/rc.d/ so you'd edit that script with the args.
EDIT: here are some links that explain:
https://wiki.archlinux.org/index.php/Rc.conf#Daemons
https://wiki.archlinux.org/index.php/Writing_rc.d_scripts
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
I want to write some notes in the draft of a LaTeX document, and at a later point I want to compile the document without them. I saw someone doing something like the following (but I forgot what he did). Write notes as {\scriptsize some_text}, and in the end replace all {\scriptsize ...} with {} with a \newcommand. But I can't figure out how to write a \newcommand to replace all {\scriptsize some_text} occurrences by empty strings. I can then just comment or uncomment the \newcommand line.
Declare in the beginning of your file
\somevariabletrue
%\somevariablefalse
so you can quickly uncomment one and comment second, and in the later part of your code:
\ifsomevariable
...
\else
...
\fi