A command-line interface (or CLI) is a method of interacting with your OS or software by typing commands on your keyboard.

learn more… | top users | synonyms (3)

0
votes
0answers
31 views

Removing special characters (spaces, newlines, tabs) from a text file

I have a flat file (1252 ANSI-Latin 1 encoding) that I wrote out from querying a third party's SQL database that has within it extraneous characters. To make it easier to reformat, I am writing it ...
0
votes
1answer
22 views

How do I correctly return context from a gnuwin32 grep (grep in windows cmd)?

I want to return a line of context after the string I'm searching for as per grep --help Context control: -B, --before-context=NUM print NUM lines of leading context -A, --after-context=NUM ...
1
vote
1answer
35 views

How make Cmder newly opened tabs go to the directory of the already opened tab?

What I want is that when I press Ctrl+T to open a new tab in Cmder, the new tab is opened in the same directory that I was in when hit Ctrl+T. With this I will avoid a lot of cd that I'm doing right ...
0
votes
1answer
22 views

How do I use command line to make an mp3 file an Mp4 file with visualisations? Is it possible to batch convert a folder with MP3's into videos?

I have a folder filled with mp3 files. I would like to render them as mp4 video files with music visualisations - is there a way to do this though command line?
0
votes
0answers
13 views

How can I setup a default windows 8.1 alarm through command line

I want to setup a new alarm for the default windows 8.1 alarm app through command line. something like "start alarm.exe AlarmName -time=SomeUnixtime -freq=once" Or through powershell or whatever ...
0
votes
3answers
42 views

Use batch to make duplicate files based on one extension

How can I make copies of some files with a specific extension (but changing the extension) just based on their extension? I've tried just showing those files but get nothing: @echo off for %%f in ...
0
votes
1answer
24 views

Getting GUID from Mountvol in Batch file

This is sort of silly, but today is the first day I'm using batch scripts, so bear with me. I'm using the following code to find a particular drive letter assigned to a volume. set ...
1
vote
1answer
48 views

How to silently install the Microsoft Monitoring Agent

I am trying to install an .exe application (Win32 Cabinet Self-Extractor) silently from command line using this PowerShell command: Start-Process -FilePath "C:\Temp\MMASetup-i386.exe" -ArgumentList ...
2
votes
1answer
55 views

Trying to get ADB command in Linux (for copying timestamps) to work with spaces in names

Using Linux Mint 13, I have been trying to ADB copy files and directories to a connected Android over USB. Need to preserve the timestamps. (I am aware that in Unix, only Time Modified is stored). ...
1
vote
1answer
45 views

How do I edit an xmlTV file using sed (or a similar tool)?

I have an xmlTV file that looks like this: <channel id="10125.dvb.guide" <!-- number="62" type="0x1" flags="0xf" bouquet="4097" region="4a" sid="10125" -->> <display-name>ITV ...
0
votes
0answers
14 views

how to keep bash buffer in sync between ansi-term line mode and char mode

when switch into term-line-mode, if bash buffer is not clear first, the original text will be left in the front of edited line, I tried to first kill the line in term-char-mode then paste it in ...
0
votes
2answers
36 views

How to write to a batch file to tell it to write to another batch file

How to write to a batch file a command which itself writes to another file. Basically what I'm trying to achieve is this File1.bat echo abc >> op.txt File2.bat echo abc >> op.txt ...
1
vote
1answer
34 views

Overwrite file on remote server with psftp if it exists only

I am a newbie with command line and PSFTP command line upload, I am used to FileZilla but at the moment, I am uploading some files with extension (.js, .php, .txt) to my remote server via PSFTP ...
2
votes
2answers
79 views

Command Prompt Shutdown Command

Setup I am running a Windows 7 PC and a Windows 7 Laptop both connected to a router forming a LAN. So, I want to remotely shutdown the laptop from the PC. I found out I could do this in command ...
0
votes
0answers
19 views

Robocopy using souring source and destination pc as shared folders

Scenario: I have 3 pc's on the network. Lets name it A, B and C PC A - used to run robocopy. PC B - has shared folders on the network - source. PC C - has folders onto which files from B are ...
2
votes
1answer
25 views

Navigate to the biggest directory in a directory in windows cmd

I am inside a directory which contains two directories - "games" and "music" and I want to descend into either "games" or "music" depending on which one has a bigger size.
0
votes
2answers
64 views

Why cmder does not import the user path variables?

The path variable in the cmder only contains those paths imported form the system path variable. While in normal command shell, the system path and user path will be concatenated. I've found in the ...
0
votes
1answer
18 views

How to use emacs CLI on a Linux server remotely from Windows

I have emacs-nox installed on a CentOS 6.5 server. I had been using PuTTY from Windows to remote into this server. However, I discovered that in emacs, I cannot hit Ctrl+A (somewhat like other ...
0
votes
1answer
28 views

Windows: recursively search for, and execute, batch file from command line

I have a project with nested folders. I want to be able to recursively look up directories until a "build.bat" file is found, and execute it. How can I do this from the command line? (i.e. not a ...
0
votes
0answers
34 views

Create Bootable USB drive with “Press Any Key To Boot” Message

I'm trying to make a usb bootable trough command line. I can do it but there is a problem. I will boot automatically without any prompt! I need to see "Press Any Key To Boot..." first and decide to ...
-1
votes
0answers
17 views

Sending data through Telnet established connection on windows command line

I have connected to an outside server using telnet on windows. I have a program written in Ruby running on my local machine whose output needs to be passed as a command in the server running. How do I ...
0
votes
2answers
65 views

%%f in a batch file with Windows 7 Professional 64 bit

I have a line like the following in a several batch files: FOR %%f IN (%*) DO something.exe %%f I've used them for a long time with no problem. I recently had to replace my hard drive and had ...
0
votes
4answers
72 views

How does piping/redirection in Linux work exactly?

I have these three examples of redirection stdin/stdout, only one of them is working the way it is intended to. I would love if someone can explain that to me. The goal is to sort the contents in ...
-1
votes
1answer
31 views

Window 7 commands not running

Specifically trying attrib, but I believe all commands in System32 don't work. I had an issue with a path variable, which I believe is fixed now, since C:\Windows\System32 is showing at the end of my ...
0
votes
1answer
24 views

How to stop DIR command counting “Thumbs.db”

We have a process that executes a DIR on multiple folders to check that the correct documents have been generated by another process. In each of the target directories we use this command: dir /A:-D ...
0
votes
2answers
35 views

tar: How to remove files after packing but keep directory

I want tar to pack a complete directory tar cvjf dir.tbz dir But make it delete all files tar cvjf dir.tbz dir --remove-files However this removes ./dir too. So I tried to cd into directory ...
0
votes
0answers
10 views

Listing specific software on group of remote machine

psinfo -s \10.101.4.204 > out.txt above command displays all software installed on 10.101.4.204 I need to find only specific software installed on remote machine
0
votes
1answer
26 views

Why does the command-not-found handler trigger for a command that exists?

I had a package (in this case, Docker) for which the version available in the Ubuntu repos was too old, so I added the Docker repo to my apt sources and installed the package from there. Now, with my ...
-1
votes
0answers
16 views

How do I launch Robocopy with a scheduled batch file and not have the command prompt appear? [duplicate]

I'm using Robocopy to keep two hard drives constantly synced up. I've created a task which runs the following batch file: @echo off robocopy "D:" "L:" /MIR /Z /MOT:1 /MON:1 /XA:H /R:1000000 /W:5 ...
0
votes
1answer
62 views

Delete all files in the folder except one extension(say .idf) using batch file [duplicate]

My current code to delete all files in a folder older then 2 days is : forfiles /p "C:\Test" /s /m *.* /c "cmd /c Del /F /Q @path" /d 2 There is one .idf file among all other files. I want to ...
0
votes
0answers
23 views

How to run specified terminal command from context menu on right clicked folder?

I'm quite happy I found out about Finder > right-click > "New Terminal at Folder". To make it perfect, I'm looking for a way to run a specified command right after. Automator doesn't seem to have such ...
0
votes
1answer
30 views

Run Spyder as a ConEmu tab

Is it possible to run Spyder ([I]Python IDE) inside a ConEmu tab? I use Notepad++ as an external editor in Far Manager & it runs inside one since I've added -new_console to my external editor ...
0
votes
0answers
17 views

In Windows, how to search in a specific Wi-Fi channel?

In Linux, it is possible to "keep searching" in a specific channel (using airodump-ng): airodump-ng -c 5 mon0 if I keep searching in a channel for more than 10 seconds, I notice that some new APs, ...
0
votes
2answers
32 views

Log Commands Run Over SSH on Client Side

I am looking for a way to run SSH (OpenSSH in particular, but not necessarily) and log all commands that I run against the remote, to a file locally. Running each command as an independent ssh ...
0
votes
2answers
27 views

grep and sed with pipe from tail -f appears to be caching

I am trying to get a working system to monitor special logs. I usually just want a very specific pattern which I extract using grep and a pipe from tail -f. I have noticed that grep does not output ...
1
vote
1answer
31 views

Copy Command with “%” in path name

I am trying to write a bat file to copy some files into a new directory (which exists). Here is my command: copy ".\050-9800-JJJ-DSC-BAW-MEE-00019-01*.pdf" "T:\201201.00 TCO - Tengiz, ...
2
votes
0answers
40 views

What are the underlying Windows7 mechanics that are responsible for opening selected files via key 'Enter'?

I need to create a batch script that opens n files, of same type and same suffix, with program p, without creating n instances of p (i. e. use multiple tabs instead of multiple instances). For some ...
0
votes
3answers
47 views

How do you write to a file within the command line?

Specifically mac, but for future reference for those that come across this post, this could be on any OS. So am learning the command line, and one utility (perhaps the only one) which seems to be ...
1
vote
2answers
48 views

Why does the set command display more environment variables than the environment variables gui?

When I run the set command in command prompt the first variable I see is But when I open my Environment Variables GUI I don't see ALLUSERSPROFILE Why is that? There are numerous other ...
0
votes
0answers
24 views

'.' is not recognized as an internal or external command

def evaluate(str, par): return (os.system("./LKH %s" %par) - swap_2opt_solve_str(str)[1])**2 I have an executable lkh file in the directory. However when my program runs this function, it gives the ...
0
votes
0answers
12 views

How to make Chrome when launched by other programs use my command lines i defined?

For security concerns, i've set chrome to launch with this: --cipher-suite-blacklist=0x0005,0x0004,0xc011,0xc007 --ssl-version-min=tls1.2 I use Windows 7, and when i click it from my TaskBar it ...
0
votes
1answer
48 views

How to access Kitematic host computer's command line

I installed Kitematic to my Mac. Kitematic installs a Linux server to VirtualBox to work as a Docker host and has a simple GUI for the basic Docker tasks etc. Now I'm wondering, how to have command ...
2
votes
2answers
38 views

Using notepad++ command line commands

I am trying to use the -l parameter in a notepad++ command line to open a file and have the highlighting be set to highlight for C++. I typed in the command: notepad++ -lC++ file.cpp For some ...
2
votes
3answers
46 views

Parse string using batch script

How can I parse string using batch script? Goal is to save in a array everything under Import: and strip out #head for example --> //MPackages/Project/config/abc.txt and ...
1
vote
1answer
30 views

What is the best policy for running GUI programs from CLI to silence non-error messages?

When, on Linux, running graphical programs (such as Sublime Text for example) from the Terminal, the program runs fine but logs on the console messages that are not exactly failures, nor useful log ...
1
vote
1answer
38 views

How can I edit local Group Policy settings using command line?

I'm attempting to throw together a script for work that allows BitLocker without a compatible TPM. The setting is "Configuration \ Administrative Templates \ Windows Components \ Bit Locker Drive ...
0
votes
1answer
53 views

How to run Windows SDK Command Prompt from command line?

I have instruction to run Select Start --> All Programs --> Microsoft Windows SDK v7.1 and open Windows SDK 7.1 Command Prompt. which is obsolete for Windows 8.1 I have installed something ...
0
votes
1answer
40 views

Windows: How can I use the command line to set registry permissions

OS: Windows 7 Desirable Method: Command Line Other acceptable methods: VBScript How can I use the command line to set registry permissions? I found the REGINI utility, but I'm not having any luck ...
3
votes
2answers
40 views

Command Line Sort Files or Directories by part of their name

How do I sort files or directories by part of their name, specifically the element contained in the parenthesis or separated by delimiter? I am after two separate solutions one for directories with ...
0
votes
1answer
32 views

Python logging class not working when sending stdout to /dev/null

I have a Python 3 script that has logging enabled (for debugging purposes). Whenever I run/execute this script it is working fine and the logfiles are created. I've also created a setup.sh-bash ...