Questions tagged [command-line-arguments]
The command-line-arguments tag has no usage guidance.
308
questions
0
votes
2
answers
19
views
How to logs result to file AND display when using W10 CMD.EXE? [duplicate]
When using Windows 10 command prompt, i know i can log the results to file by doing this :
dir c:\ > results.txt
But problem is, doing this , the results are NOT displayed on the screen.
Is there a ...
0
votes
1
answer
34
views
Firefox: how do I configure kiosk mode?
Mozilla's website states:
Numerous features of the kiosk mode are configurable through policy or
command line parameters when launching the browser.
However, other than a single example to run kiosk ...
0
votes
0
answers
21
views
How to run .js script on Chromebook?
I have saved a .js script that enables backing up chrome://flags from DevOps console. Running the .js script directly from console does not work though, and after a bit of research, I see that the ...
0
votes
0
answers
17
views
GPT disk missing EFI partition
A new Win 10 Pro install on new WD Black SN750 NVME is missing the EFI partition. How can I create the EFI partition using command prompt? If not then using Powershell … whic I’m not that familiar ...
0
votes
0
answers
23
views
Is there a way to Name a specific Chrome Window on startup?
I would like to be able to open chrome, either by clicking on the chrome.exe or by clicking on a URL, and as a result, chrome would launch with a specific window name.
I just want to have my chrome ...
0
votes
0
answers
26
views
what is the equivalent of ctrl+h (find and replace) in cmd command line
I need instructions specific to the command line (Windows 10) to modify a text file, by replacing a word with another word I thought of the for loop but I did not find a command to modify a file text?
...
0
votes
0
answers
14
views
Starting VSCode with WSL Distro (from command line.)
is there a way to launch vscode from command line, and to tell it to start a new WSL window (using the default WSL distribution.)
I don't see an option in the CLI, and regardless of whether I launch ...
1
vote
1
answer
40
views
Reimplementing lrzip decompress on Windows explorer using WSL
I've downloaded an old version of lrzip decompressor for windows and noticed that it's using the cygwin libraries in order to run the program itself.
The benchmarks comparing WSL2 and cygwin say that ...
1
vote
0
answers
23
views
How to pass the arguments while executing a script where variable name is not known?
I have a script, when i execute it ask couple of arguments one by one.
[home]$ ./script_name
User> *input here*
Password> *input here*
Authentication ID> *input here*
Success !!
Select the ...
-1
votes
1
answer
48
views
Windows 10, cmd start with & in the command path
I'm now using OneDrive for work. This has caused me some problems with a specific command that I have pined. The OneDrive path now contains spaces dashes and an ampersand.
C:\Windows\System32\cmd.exe /...
0
votes
0
answers
243
views
Windows Shortcut with Relative File Path
I have created a tool that uses Google Chrome App Mode to work. In order to access it, I have a shortcut to google chrome that opens the specific html page. Currently, I have an absolute path, but I ...
0
votes
1
answer
176
views
How can I run a powershell command as admin programmatically?
I want to run a powershell command as admin through programming languages as VBScript. I have seen this stackoverflow answer but Start-Process only runs executable and not really a powershell command ...
2
votes
1
answer
1k
views
Start Command Prompt always as admin through Windows Terminal
How can I make Windows Terminal always run Command Prompt as admin so I can issue elevated commands?
0
votes
1
answer
70
views
Command Prompt Shortcut .lnk That Runs Program
You can set up command prompt shortcuts so that the window has specified colors, sizes, and locations on the screen. I have many of these set up for many different programs that I like to see all at ...
0
votes
0
answers
170
views
Intellij Idea changes run configuration maven -Dexec.args quotes
I'm using IntelliJ IDEA to run a maven project. In Run/Debug Configuration pop up dialog, I add a maven config with such parameters:
exec:java -Dexec.args="-p 7070"
But to my surprise when ...
0
votes
1
answer
115
views
Regex in youtube-dl arguments
I want to extract two paths from the youtube-dl arguments, the output template and ffmpeg location
-o (.*%\(ext\)s).* --ffmpeg-location (.*)
With the regex above I am able to capture both the output ...
2
votes
1
answer
372
views
Command line arguments: How to launch 7zFM.exe like the context menu does, so that prepared 7z GUI appears?
7z file manager (7zFM.exe) can be launched via context menu.
This conveniently produces the 7z GUI already prepared for archiving. All I need to do is change the archive name and maybe add a password....
1
vote
2
answers
673
views
Is there a way to view or store file history (like browser history) in Linux?
Is there any way to "view" (or) "store" file history (similar to browser history). For example if I have 10 files, and I open 2 of them, the following 2 details should get stored ...
1
vote
1
answer
106
views
Passing list of file paths in variable as arguments to command
Scenario:
kdialog --menu takes a list of strings of the form title element label element label .... Now, the issue with this is that spaces are used as delimiters.
Let's say I have a string variable $...
0
votes
1
answer
25
views
Running system rm -rf on an online compiler
I have not written the command using proper syntax in order to prevent any accidental misfire
I recently read about the danger of using the command rm -rf in root directory but was wondering about a ...
0
votes
0
answers
30
views
Windows 10, cmd, schtasks, varying arguments
Let's say that a given scheduled task simply runs a batch script (*.bat or *.cmd).
Is it possible to pass varying command line arguments to such script?
With "varying", I mean, the arguments ...
0
votes
1
answer
96
views
List of JSON strings as command arguments
I've been working with GitLab CI recently to automate some busy tasks, namely auto releasing binaries for version tags.
For those who don't know Gitlab CI, it is very straightforward. It pulls the ...
1
vote
1
answer
296
views
Using ffmpeg on Raspberry Pi to grab video from RTSP: "-t command not found"
I am trying something that should be simple - trying to use the Raspberry Pi ffmpeg to grab a 30 second video from an RTSP stream. The command looks like this:
ffmpeg -i <rtsp:...> -t 30 <...
0
votes
1
answer
79
views
What is the equivalent of shell variables $@ in windows command?
I want to put a variable in my command batch script for multiple arguments as the number may vary. Just as in shell we use $@. I tried several things but nothing is working.
[Edit : I know %* works, ...
0
votes
1
answer
120
views
WSL translate W10 CLI switches into Linux?
I'm trying to install Veracrypt and run it (mount volumes, etc.) from a script run in WSL (Python but can call a BASH script obviously).
As documented here, I've encountered a problem trying to use ...
0
votes
1
answer
174
views
How to use Linux to Partition and Format a blank external hard drive where the partitions were lost
I need some help rescuing a new and blank 4 terabyte external SSD USB hard drive.
The original partitions were 3.64T and a 0.36 partition labeled "Microsoft Partition"
Using GParted, I ...
1
vote
1
answer
173
views
bash command: How to automatically enter menu choices that come up later during installation?
During apt-get install -y python-catkin-tools on Ubuntu you have to enter timezone numbers 8 for the region and 7 for a city when "tzdata (2020f-0ubuntu0.18.04)" gets installed.
How can I ...
0
votes
1
answer
45
views
How to chain command arguments to a specific command binary
I have general question about chaining commands to one specific binary in bash shell, with examples from Magento (use case)
In Magento you commonly want to chain many commands together - they take ...
0
votes
0
answers
53
views
Launching a command from a physical keyboard shortcut
I have the Logitech Ergo K860 keyboard that has some programmable keys. I want a key to launch a specific RDP connection.
Just to test it out, I tried:
CMD
and it launched a Command window.
OK, so ...
0
votes
1
answer
70
views
Changing which command line program runs when there are two programs with the same name
When I run where java, the output is:
C:\Program Files (x86)\Common Files\Oracle\Java\javapath\java.exe
C:\Program Files\Java\jdk-13.0.2\bin\java.exe
Both of these programs are called 'java', but the ...
2
votes
2
answers
2k
views
Why won't CMD on Windows 10 allow me to finger anyone?
Reading This Article: Digital Trends CMD Commands.
I Found A command Called Finger.
Trying it out on My System, Windows 10
Why won't it let me Finger anyone..
Says Connect: Connection Refused?
Not ...
1
vote
0
answers
106
views
Opening URL in specified Firefox profile from command line
Is there a way how I can let Firefox open a link in new tab from command line for specified profile? Ideally in a way in which it doesn't matter, whether Firefox is already running or not
I know I can ...
1
vote
2
answers
149
views
What does /#/ symbol mean in the context of ${}?
In the context of the following function
function foo { local d="d"; printf "%s" "${@/#/$d}"; }
what does the /#/ mean?
When I call foo a b c it returns dadbdc.
1
vote
1
answer
903
views
pass parameters to batch file via File URI in Windows
Using Windows 10 here.
Code in open_video.bat
"%USERPROFILE%\Desktop\VLCPortable media player\VLCPortable.exe" --start-time=54 --stop-time=89 "%USERPROFILE%\Downloads\some_video.mkv&...
2
votes
1
answer
40
views
How to separate command switches (/x) from arguments in windows?
I know in linux, I can just write command -a -b - "arg1" "arg2"..., where single hyphen is "option/switch" separator. But how can I do similar in windows cmd?
I would ...
1
vote
2
answers
46
views
Why man read don't contain any argument description in my debian? [duplicate]
As far as i know that read in bash contains many argument such as -a -d -e -r.
The webpage list all arguments of read.
read's arguments
In my console, man read contains no argument on it.
I upload man ...
14
votes
2
answers
6k
views
What does "robocopy /NOOFFLOAD" do?
The windows tool robocopy has a command line switch /NOOFFLOAD. What does this switch actually do, and under what circumstances would I use it?
The documentation for the switch says
/NOOFFLOAD :: copy ...
1
vote
0
answers
26
views
How to use files copied in Windows File Explorer on the command line? [duplicate]
In Windows File Explorer, you can highlight several files and then click the "Copy path" button from the menu. Show below is an example. I'd then like to process these files on the command line, ...
0
votes
0
answers
69
views
File assocations inconsistent behaviour with Windows 10
After updating Python, my file associations somehow got messed up and I have been trying to get them to behave. Here's my test program PyArgs.py:
import sys, os
print ("Arguments count : "...
1
vote
1
answer
577
views
How to use command line tool "unzip" to only grab a certain folder?
I have a .jar file which can be opened with the Command line tool "unzip", which has this option called -p so you can grab certain files. But how do you do this with a folder? Here's what this jar ...
4
votes
2
answers
2k
views
How to make an app minimize itself after some time?
Is there an argument to specify for an app to minimize itself after being launched after a certain delay in Windows?
I made a .bat file to be able to launch multiple apps with one launcher, I ...
0
votes
1
answer
896
views
Is /min a valid switch for cmd.exe in Windows?
I'm looking at a few batch files (.bat), and they use use /min as a switch for cmd.exe. Looking at several references, I don't see /min as a parameter for cmd.exe.
Is /min a valid switch for cmd.exe ...
0
votes
0
answers
1k
views
"Error 1722 getting session names" Can I use the msg in cmd to message another person if we are using the same WiFi connection?
Previously I have tried to message myself in cmd through using my WiFi as the server name and if I'm not not wrong it seems to work however I always get the same error Error 1722 getting session names ...
1
vote
1
answer
119
views
Open "Find Printer" from command line. Not "Add Printer"
Windows 10
Is it possible to modify this entry to open the "Find Printer" dialogue?
RUNDLL32.EXE PRINTUI.DLL,PrintUIEntry /ii /f %windir%\inf\ntprint.inf
I am able to open "Add Printer" with this ...
0
votes
1
answer
46
views
Dealing with files with spaces inside a FOR loop from files passed in command line in bash is failing
I am creating a script that will crop movies and have the following syntax:
./crop *.mov 0,0,100,100
or
./crop oneMovie.mov 0,0,100,100
So, the first parameter can be a wildcard pattern or one ...
0
votes
1
answer
434
views
Task manager: Hide when minimized without GUI
When you launch taskmgr.exe, there is an option "Hide When Minimized" (under Options menu).
I am looking for how to run it with that option without using GUI in the task manager itself.
That is, a ...
2
votes
3
answers
3k
views
Passing '&' as text in parameter in batch file
I am trying to pass an argument to a BAT file thru VB Shell function. argument text value looks like this say Hello&123
As you noticed there's an '&' as text in it. However & is reserved ...
0
votes
2
answers
874
views
Is there a way to start the Slack app with a maximised window but still run in the background?
I want to have the Slack desktop application run at startup in the background as it normally does with the Launch app on login settings. However this always results in a small sized window when I open ...
0
votes
1
answer
2k
views
Pass parameters to Windows Terminal?
Currently I am using MinTTY for my Cygwin terminal needs. Lacking a tabbed interface, I am looking to move to "Windows Terminal", which is currently distributed as a Store app on Windows 10.
...
0
votes
0
answers
4k
views
How do I start Chrome with specific window size, position, and profile?
I'm trying to open Chrome to a specific user while also having a specific window size and position using CMD on Windows. It seems that I can either open to a specific profile or mess with the window ...