August 24, 2005 Archives

24.08.2005 13:59

Interactive or non-interactive

Vectorlinux nicely prints to the screen info about who you are, and what commands you have at your disposal. Screenshot of Vectorlinux terminal login This is nice but can halt programs that do non-interactive logins, like scp. So off I go finding where Vector does this and how to make the script test for interactivity before printing to the terminal. After a bit of googling I found this handy link. http://www.cs.sunysb.edu/documentation/bash/bashref.html#TOC62. So now to apply this info to Vector. I searched through and found:
  • /etc/profile.d/vasm.sh
This file was responsible for printing that info to the terminal. So basicly I applied that if statement found on the link above around all the info in the vasm.sh file. Also, I pulled out the non-interactive part of the file and put it outside the now interactive executed section so it would be ran if it was an interactive or non-interactive login. Here's the files, now altered to work with scp.

Posted by DaveQB | Permanent Link | Categories: IT