Skip to main content

Questions tagged [windows]

Writing software specific to the Microsoft Windows operating system: APIs, behaviours, etc. GENERAL WINDOWS SUPPORT IS OFF-TOPIC. Support questions may be asked on https://superuser.com

Filter by
Sorted by
Tagged with
3343 votes
34 answers
5.6m views

How do I find out which process is listening on a TCP or UDP port on Windows? [closed]

How do I find out which process is listening on a TCP or UDP port on Windows?
readonly's user avatar
  • 351k
2850 votes
26 answers
912k views

Is there an equivalent of 'which' on the Windows command line? [closed]

As I sometimes have path problems, where one of my own cmd scripts is hidden (shadowed) by another program (earlier on the path), I would like to be able to find the full path to a program on the ...
namin's user avatar
  • 37.8k
2756 votes
40 answers
3.5m views

How do I install pip on Windows?

pip is a replacement for easy_install. But should I install pip using easy_install on Windows? Is there a better way?
1550 votes
21 answers
1.9m views

Ignoring directories in Git repositories on Windows

How can I ignore directories or folders in Git using msysgit on Windows?
sf.'s user avatar
  • 25.2k
1513 votes
19 answers
1.4m views

Filename too long in Git for Windows

I'm using Git-1.9.0-preview20140217 for Windows. As I know, this release should fix the issue with too long filenames. But not for me. Surely I'm doing something wrong: I did git config core.longpaths ...
Papa Mufflon's user avatar
  • 19.2k
1362 votes
28 answers
3.7m views

How can I close some specific port on Linux? [closed]

How can I remove the port that some application/process has used it but didn't close the port? For example: when I run ssh on my ubuntu and tunnel the ssh connection on some port <PORT> on my ...
KavinduWije's user avatar
  • 41.9k
1356 votes
25 answers
1.6m views

How do I run two commands in one line in Windows CMD?

I want to run two commands in a Windows CMD console. In Linux I would do it like this touch thisfile ; ls -lstrh How is it done on Windows?
flybywire's user avatar
  • 269k
1269 votes
43 answers
1.1m views

How can I develop for iPhone using a Windows development machine?

Is there any way to tinker with the iPhone SDK on a Windows machine? Are there plans for an iPhone SDK version for Windows? The only other way I can think of doing this is to run a Mac VM image on a ...
1259 votes
27 answers
1.1m views

Git replacing LF with CRLF

On a Windows machine, I added some files using git add. I got warnings saying: LF will be replaced by CRLF What are the ramifications of this conversion?
mrblah's user avatar
  • 102k
1191 votes
17 answers
991k views

How to upgrade Git on Windows to the latest version

I just upgraded to Git 1.8.0.1 for Windows, from my previous version 1.7.9.mysysgit.0. I downloaded the new version from the Git site and installed through the normal Git installer EXE. That said, ...
BrianScottK's user avatar
1188 votes
8 answers
1.9m views

List all environment variables from the command line

Is it possible to list all environment variables from a Windows' command prompt? Something equivalent to PowerShell's gci env: (or ls env: or dir env:).
Nicola Cossu's user avatar
  • 55.8k
1109 votes
9 answers
408k views

Node.js/Windows error: ENOENT, stat 'C:\Users\RT\AppData\Roaming\npm'

I have Windows 7 32-bit. I installed the latest Node.js 32 bit. When I try to run the command npm install jquery, I receive the error: Error: ENOENT, stat 'C:\Users\RT\AppData\Roaming\npm How ...
tryasko's user avatar
  • 11.2k
1044 votes
44 answers
1.7m views

Can't start Eclipse - Java was started but returned exit code=13

I am trying to get my first taste of Android development using Eclipse. I ran into this problem when trying to run Eclipse, having installed version 4.2 only minutes ago. After first trying to start ...
Ben E.'s user avatar
  • 10.6k
1040 votes
17 answers
3.1m views

How to run a PowerShell script

How do I run a PowerShell script? I have a script named myscript.ps1 I have all the necessary frameworks installed I set that execution policy thing I have followed the instructions on this MSDN help ...
Pekka's user avatar
  • 447k
1022 votes
2 answers
2.1m views

Text editor to open big (giant, huge, large) text files [closed]

I mean 100+ MB big; such text files can push the envelope of editors. I need to look through a large XML file, but cannot if the editor is buggy. Any suggestions?
1010 votes
42 answers
1.7m views

Remove credentials from Git

I'm working with several repositories, but lately I was just working in our internal one and all was great. Today I had to commit and push code into other one, but I'm having some troubles. $ git ...
balexandre's user avatar
  • 74.6k
1003 votes
24 answers
1.2m views

Setting Windows PowerShell environment variables

I have found out that setting the PATH environment variable affects only the old command prompt. PowerShell seems to have different environment settings. How do I change the environment variables for ...
Vasil's user avatar
  • 37.6k
989 votes
7 answers
1.1m views

How do I get the application exit code from a Windows command line?

I am running a program and want to see what its return code is (since it returns different codes based on different errors). I know in Bash I can do this by running echo $? What do I do when ...
Skrud's user avatar
  • 11.8k
969 votes
39 answers
1.6m views

Failed to load the JNI shared Library (JDK)

When I try opening Eclipse, a pop-up dialog states: Failed to load the JNI shared library "C:/JDK/bin/client/jvm.dll"`. Following this, Eclipse force closes. Here's a few points I'd like to make: ...
902 votes
12 answers
575k views

Windows batch files: .bat vs .cmd?

As I understand it, .bat is the old 16-bit naming convention, and .cmd is for 32-bit Windows, i.e., starting with NT. But I continue to see .bat files everywhere, and they seem to work exactly the ...
Chris Noe's user avatar
  • 36.9k
878 votes
43 answers
962k views

error: Unable to find vcvarsall.bat

I tried to install the Python package dulwich: pip install dulwich But I get a cryptic error message: error: Unable to find vcvarsall.bat The same happens if I try installing the package manually: ...
okada's user avatar
  • 8,789
871 votes
2 answers
381k views

How do SO_REUSEADDR and SO_REUSEPORT differ?

The man pages and programmer documentations for the socket options SO_REUSEADDR and SO_REUSEPORT are different for different operating systems and often highly confusing. Some operating systems don't ...
Mecki's user avatar
  • 131k
852 votes
7 answers
698k views

How can I redirect Windows cmd standard output and standard error to a single file?

I'm trying to redirect all output (standard output and standard error) of a Windows command to a single file: C:\ cd \ dir 1> a.txt 2> a.txt Output: The process cannot access the file because ...
ripper234's user avatar
  • 228k
840 votes
15 answers
1.3m views

How to export/import PuTTY sessions list?

Is there a way to do this? Or I have to take manually every record from Registry?
s.webbandit's user avatar
  • 16.7k
792 votes
27 answers
1.3m views

How can I echo a newline in a batch file?

How can you you insert a newline from your batch file output? I want to do something like: echo hello\nworld Which would output: hello world
Brian R. Bondy's user avatar
789 votes
17 answers
421k views

What is the difference between Cygwin and MinGW?

I want to make my C++ project cross platform, and I'm considering using Cygwin/MinGW. But what is the difference between them ? Another question is whether I will be able to run the binary on a ...
Łukasz Lew's user avatar
  • 49.7k
780 votes
42 answers
864k views

How do I run Redis on Windows?

How do I run Redis on Windows? The Redis download page just seems to offer *nix options. Can I run Redis natively on Windows?
DaveHeller's user avatar
  • 8,009
758 votes
25 answers
1.4m views

Batch file to delete files older than N days

I am looking for a way to delete all files older than 7 days in a batch file. I've searched around the web, and found some examples with hundreds of lines of code, and others that required installing ...
Kibbee's user avatar
  • 66k
744 votes
22 answers
2.4m views

Adding a directory to the PATH environment variable in Windows

I am trying to add C:\xampp\php to my system PATH environment variable in Windows. I have already added it using the Environment Variables dialog box. But when I type into my console: C:\>path it ...
Netorica's user avatar
  • 19.1k
735 votes
61 answers
2.2m views

pip install fails with "connection error: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:598)"

I am very new to Python and trying to > pip install linkchecker on Windows 7. Some notes: pip install is failing no matter the package. For example, > pip install scrapy also results in the SSL ...
Jeremy Cook's user avatar
  • 21.6k
730 votes
11 answers
567k views

CSV file written with Python has blank lines between each row

import csv with open('thefile.csv', 'rb') as f: data = list(csv.reader(f)) import collections counter = collections.defaultdict(int) for row in data: counter[row[10]] += 1 with open(...
Alex Gordon's user avatar
  • 59.3k
719 votes
23 answers
1.7m views

How do I install and use cURL on Windows? [closed]

I am having trouble getting cURL to run on Windows. I have downloaded a cURL zip file from here, but it seems to contain source code, not an executable. Do I need to compile cURL to run it? If yes, ...
pri_dev's user avatar
  • 11.5k
716 votes
24 answers
1.1m views

"rm -rf" equivalent for Windows?

I need a way to recursively delete a folder and its children. Is there a prebuilt tool for this, or do I need to write one? DEL /S doesn't delete directories. DELTREE was removed from Windows 2000+
FlySwat's user avatar
  • 175k
710 votes
36 answers
1.4m views

Unable to resolve "unable to get local issuer certificate" using git on Windows with self-signed certificate

I am using Git on Windows. I installed the msysGit package. My test repository has a self signed certificate at the server. I can access and use the repository using HTTP without problems. Moving to ...
RichardHowells's user avatar
701 votes
20 answers
761k views

What characters are forbidden in Windows and Linux directory names?

I know that / is illegal in Linux, and * " / \ < > : | ? are illegal in Windows. What else am I missing? I need a comprehensive guide that also accounts for double-byte characters.
Jeff's user avatar
  • 15.6k
699 votes
30 answers
861k views

Is there a command to refresh environment variables from the command prompt in Windows?

If I modify or add an environment variable I have to restart the command prompt. Is there a command I could execute that would do this without restarting CMD?
Eric Schoonover's user avatar
685 votes
10 answers
2.5m views

How do I shutdown, restart, or log off Windows via a bat file?

I've been using Remote Desktop Connection to get into a workstation. But in this environment, I cannot use the power options in Start Menu. I need an alternative way to shutdown or restart. How do I ...
Keng's user avatar
  • 52.7k
683 votes
21 answers
1.0m views

How to prevent auto-closing of console after the execution of batch file

What command can I put at the end of a batch file to prevent auto-closing of the console after the execution of the file?
joe's user avatar
  • 17.4k
673 votes
27 answers
2.1m views

Error "'git' is not recognized as an internal or external command"

I have an installation of Git for Windows, but when I try to use the git command in Command Prompt, I get the following error: 'git' is not recognized as an internal or external command, operable ...
Jason Kim's user avatar
  • 18.8k
668 votes
7 answers
425k views

How to create file execute mode permissions in Git on Windows?

I use Git in Windows, and want to push the executable shell script into git repo by one commit. Usually I need to do two steps (git commit). $ vi install.sh $ git add install.sh $ git commit -am &...
Larry Cai's user avatar
  • 58.5k
660 votes
34 answers
581k views

How do I measure execution time of a command on the Windows command line?

Is there a built-in way to measure execution time of a command on the Windows command line?
Kuroki Kaze's user avatar
  • 8,351
657 votes
37 answers
436k views

How can I set up an editor to work with Git on Windows?

I'm trying out Git on Windows. I got to the point of trying "git commit" and I got this error: Terminal is dumb but no VISUAL nor EDITOR defined. Please supply the message using either -m or -F ...
Patrick McElhaney's user avatar
651 votes
35 answers
1.7m views

How can I create an empty file at the command line in Windows?

How can I create an empty file at the DOS/Windows command-line? I tried: copy nul > file.txt But it always displays that a file was copied. Is there another method in the standard cmd? It should ...
Grendler's user avatar
  • 6,677
645 votes
18 answers
297k views

How can I update the current line in a C# Windows Console App?

When building a Windows Console App in C#, is it possible to write to the console without having to extend a current line or go to a new line? For example, if I want to show a percentage representing ...
IVR Avenger's user avatar
  • 15.4k
642 votes
30 answers
1.8m views

How do I get current date/time on the Windows command line in a suitable format for usage in a file/folder name?

Update: Now that it's 2016 I'd use PowerShell for this unless there's a really compelling backwards-compatible reason for it, particularly because of the regional settings issue with using date. See @...
Rory's user avatar
  • 41.4k
630 votes
17 answers
1.7m views

How to create .pfx file from certificate and private key?

I need .pfx file to install https on website on IIS. I have two separate files: certificate (.cer or pem) and private key (.crt) but IIS accepts only .pfx files. I obviously installed certificate and ...
jlp's user avatar
  • 10.2k
625 votes
15 answers
845k views

How do I uninstall a Windows service if the files do not exist anymore?

How do I uninstall a .NET Windows Service if the service files do not exist anymore? I installed a .NET Windows Service using InstallUtil. I have since deleted the files but forgot to run InstallUtil ...
Thomas Jespersen's user avatar
615 votes
30 answers
1.2m views

How can you find and replace text in a file using the Windows command-line environment?

I am writing a batch file script using Windows command-line environment and want to change each occurrence of some text in a file (ex. "FOO") with another (ex. "BAR"). What is the simplest way to do ...
Ray's user avatar
  • 190k
604 votes
14 answers
954k views

Create folder with batch but only if it doesn't already exist

Can anybody tell me how to do the following in in a Windows batch script? (*.bat): Create a folder only if it doesn't already exist In more detail, I want to create a folder named VTS on the C:\ ...
Bill's user avatar
  • 6,041
600 votes
29 answers
1.8m views

How can I update npm on Windows?

I tried this: sudo npm cache clean -f sudo npm install -g n sudo n stable ...but it didn't work. How do I do this on Windows?
Jatin's user avatar
  • 14.2k

1
2 3 4 5
3376