#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2013
    Posts
    53
    Rep Power
    2

    Putty and scripts


    I am using Putty for shell, but how do I run scripts through it?

    I am on Windows.

    Do I need to transfer the script into putty first then launch it? If so how do I do that? or will it launch the scripts and input files directly from the directory I am launching putty from, and I just put the file names into the command because it is local?

    They are awk scripts.

    I'm confused.

    And can these files be in .txt format?
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Mar 2006
    Posts
    2,436
    Rep Power
    1688
    The scripts you need to run will need to reside in a location that the machine you have used putty to connect to has access. That's usually be in a file system 'local' to the machine, but could also be network or samba/cifs mounted from elsewhere.
    One obvious way of getting them there is to use sftp, scp, etc.
    The moon on the one hand, the dawn on the other:
    The moon is my sister, the dawn is my brother.
    The moon on my left and the dawn on my right.
    My brother, good morning: my sister, good night.
    -- Hilaire Belloc
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2013
    Posts
    53
    Rep Power
    2
    Originally Posted by SimonJM
    The scripts you need to run will need to reside in a location that the machine you have used putty to connect to has access. That's usually be in a file system 'local' to the machine, but could also be network or samba/cifs mounted from elsewhere.
    One obvious way of getting them there is to use sftp, scp, etc.
    Putty is connected to an school server.

    How do I transfer the script and text files that the script will effect to the server?

    sftp scp?
  6. #4
  7. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2013
    Posts
    53
    Rep Power
    2
    Ok, so I've connected to the sever via filezilla. Now I can transfer the script and text files. I use awk with the file names and extensions and its working.

    All is good. Not too complicated. But I can't use putty alone to transfer files yet. Not sure how to do this form my local computer.
  8. #5
  9. No Profile Picture
    Contributing User
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Mar 2006
    Posts
    2,436
    Rep Power
    1688
    There is a putty 'suite' which also contains an scp and sftp client which you can use to transfer files from your local pc to the server.
    The moon on the one hand, the dawn on the other:
    The moon is my sister, the dawn is my brother.
    The moon on my left and the dawn on my right.
    My brother, good morning: my sister, good night.
    -- Hilaire Belloc

IMN logo majestic logo threadwatch logo seochat tools logo