How do you use UNIX commands in the Windows Command Line?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers How do you use UNIX commands in the Windows Command Line?
# 1  
Old 06-03-2010
How do you use UNIX commands in the Windows Command Line?

I tried opening the windows command line and typing UNIX commands, but they don't work. It kept saying that it was not recognized as an internal or external command, operable program or batch file.

Moderator's Comments:
Mod Comment Removed strange sentence with even stranger link


I need to use UNIX commands such as 'less', ‘grep’, ‘cat’, ‘cut’, ‘awk’, and ‘sed’

I've heard that Cygwin can also be useful in this, if so could anyone offer directions on how to install and use that?

Thanks again for helping a very new person to this.
# 2  
Old 06-03-2010
Download executable from this link Cygwin Information and Installation

Installation is pretty simple
# 3  
Old 06-03-2010
If you used that weird "tutorial" I hardly think it would work... Smilie

You can download cygwin and use coreutils... The installation is pretty straightforward.
# 4  
Old 06-03-2010
I'm not a fan of Cygwin's path referencing, but whereas UWIN is more UNIX-like it's been a little sketchy under later Windows versions. If you're hand-cuffed to Windows, you could try the UNIX Tools here: Native Win32 ports of some GNU utilities.
# 5  
Old 06-03-2010
Quote:
Originally Posted by verdepollo
If you used that weird "tutorial" I hardly think it would work... Smilie

You can download cygwin and use coreutils... The installation is pretty straightforward.
z.I. I removed the link. It seemed to be something about baseball and nothing to do with a tutorial. Maybe my router is on the blink!
# 6  
Old 06-03-2010
Honestly, I'm still pretty lost about everything. I installed Cygwin, and I opened it up and I try and type Unix commands like '% ls' and it keeps saying "bash: fg: %: no such job"

I'm thinking there's an easy fix to this, but I am really new to UNIX commands and writing on the command line in general. I just started learning yesterday so please bear with me.
# 7  
Old 06-03-2010
Ah. You're not supposed to type the % character, that's just there to demonstrate that you're at a shell prompt.

You'll also see
Code:
# ls
$ ls

etc.

The command is
Code:
ls

 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to run UNIX commands on remote machine from windows?

Hi All, I am working in support and we are planning to automate a system to reduce the direct manual intervention to core system. Please find the below details. 1. we have a web application that runs on Windows Platform. 2. From web application, we need to connect to remote Unix machine.... (6 Replies)
Discussion started by: Balaji K
6 Replies

2. IP Networking

How to transfer files from UNIX server to windows machine or vice versa using ftp or sftp commands?

hi, i want to write a shell script code which transfers files from a directory in unix server to a directory in a windows machine.. can any1 give me a sample code which uses ftp or sftp command.. thanks very much, (3 Replies)
Discussion started by: Little
3 Replies

3. Shell Programming and Scripting

Windows Batch script for Unix commands

I wish to create a folder on a unix server B from my windows box using windows batch script. Below is my windows batch script. @ ECHO OFF ::Enter your Directory name: echo Enter your Directory name: set /p mydir= plink user1@ServerA mkdir %mydir% At plink command i get logged... (7 Replies)
Discussion started by: mohtashims
7 Replies

4. UNIX Desktop Questions & Answers

How to practice unix commands on windows 7 machine

Hello, I am pretty new to UNIX and would like to know how i can run unix commands on a windows 7 machine. Basically, I want to practice running commands, created bash/awk/etc. scripts. I've read some things about cygwin, but it doesn't sound like it's exactly what I'm looking for. Any... (4 Replies)
Discussion started by: tester213
4 Replies

5. Shell Programming and Scripting

Replace unix 'new line' with windows 'new line'

I'm trying to write a script to convert a unix text file to windows/dos format. Essentially all I want to do is replace the Unix return with a windows one. on the command line I can do this successfully by: sed s/$/^M/ ~/unix.txt ~/dos.txt when I put this line in my shell script it... (5 Replies)
Discussion started by: wha72
5 Replies

6. UNIX for Dummies Questions & Answers

How to run UNIX commands for practice in Windows 2000 OS?

How to run UNIX commands for practice in Windows 2000 OS? If you suggest to install Cygwin, please let me know the procedure to install, or else I feel happy if you suggest any stand alone app for running UNIX commands..:) (2 Replies)
Discussion started by: Srikanthk
2 Replies

7. Shell Programming and Scripting

Unix commands in one line

Hi I want to write the following code in 1 line: a=1 if then echo ok else echo not ok fi The following does not work: a=1 ; if \r then \r echo ok \r else \r echo not ok \r fi or Even if I replace \r by \n it does not work. Please suggest. (11 Replies)
Discussion started by: miltonkeynesguy
11 Replies

8. UNIX for Dummies Questions & Answers

Running UNIX commands remotely in Windows box from Unix box – avoid entering password

I am able to run the UNIX commands in a Windows box from a UNIX box through "SSH" functionality. But whenever the SSH connection is established between UNIX and Windows, password for windows box is being asked. Is there a way to avoid asking password whenever the SSH connection is made? Can I... (1 Reply)
Discussion started by: D.kalpana
1 Replies

9. UNIX for Dummies Questions & Answers

?Using Unix commands in Microsoft (Windows') DOS Prompt?

I ran a search for "Unix Dos" in the search field box and checked a few pages' results but did not find what I was looking for. I am trying to find out if there are choices of applications that would enable using Unix commands inside a Windows environment, particularly the DOS Prompt. The only... (2 Replies)
Discussion started by: HLee1981
2 Replies

10. UNIX for Advanced & Expert Users

executing applications/commands on a unix server from a windows PC

i have a network drive (samba) mounted on to my PC and also i have SSH client on my machine. however i need to run applications/commands on a unix server from the middle of a different executable(windows compatable one). so i need to connect to the unix server from SSH through the... (1 Reply)
Discussion started by: megastar
1 Replies
Login or Register to Ask a Question