Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Gamers & Players
  • Search

Nethack on login?

Having problems getting your favorite Linux game to work? Want to discuss strategies? This is the place!
Post Reply
  • Print view
Advanced search
8 posts • Page 1 of 1
Author
Message
midnightlightning
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 79
Joined: Sun Dec 19, 2004 2:35 pm
Contact:
Contact midnightlightning
Website

Nethack on login?

  • Quote

Post by midnightlightning » Thu May 25, 2006 7:00 pm

Probably more of a generic Linux question than gaming, but it applies in this case: I've got nethack installed on my Gentoo box, and want to set it up so for a particular user, nethack starts on login (via telnet or ssh) and if nethack closes, the telnet/ssh session closes. How would I go about doing that?
"Any sufficiently advanced technology is indistinguisable from magic." -- Arthur C. Clarke
Top
zxiiro
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 98
Joined: Tue Apr 27, 2004 5:26 pm
Location: Ottawa
Contact:
Contact zxiiro
Website

Re: Nethack on login?

  • Quote

Post by zxiiro » Thu May 25, 2006 7:08 pm

midnightlightning wrote:Probably more of a generic Linux question than gaming, but it applies in this case: I've got nethack installed on my Gentoo box, and want to set it up so for a particular user, nethack starts on login (via telnet or ssh) and if nethack closes, the telnet/ssh session closes. How would I go about doing that?
for that user in the .bashrc file (or whatever shell your using)

Code: Select all

echo "test"
exit
just a quick test I did don't know if it'll work for your nethack
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56078
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Thu May 25, 2006 7:10 pm

midnightlightning,

When you create that user, set the shell to the path to the nethack binary instead of to /bin/bash.
You may need to add it to /etc/shells as a permissible login shell too.

You could also make the users .bash_profile run nethack but I think that gives you a shell when nethack exits.
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
PaveQ
Apprentice
Apprentice
Posts: 225
Joined: Fri Feb 11, 2005 5:25 pm
Location: Finland
Contact:
Contact PaveQ
Website

  • Quote

Post by PaveQ » Thu May 25, 2006 7:40 pm

I think setting the login shell to the nethack is better than executing from bash. No bash gets started so theres no way to circumvent anything.

But are you aware that nethack does have known security problem in gentoo?
Top
midnightlightning
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 79
Joined: Sun Dec 19, 2004 2:35 pm
Contact:
Contact midnightlightning
Website

  • Quote

Post by midnightlightning » Thu May 25, 2006 8:32 pm

PaveQ wrote:I think setting the login shell to the nethack is better than executing from bash. No bash gets started so theres no way to circumvent anything.

But are you aware that nethack does have known security problem in gentoo?
Yes, I've seen that, and for right now I'm not opening up the box to the world (only on my local network), so I think I'll be fine; plus it's not a mission-critical box to have up.

Thanks for the tips with the shell setting!
"Any sufficiently advanced technology is indistinguisable from magic." -- Arthur C. Clarke
Top
zxiiro
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 98
Joined: Tue Apr 27, 2004 5:26 pm
Location: Ottawa
Contact:
Contact zxiiro
Website

  • Quote

Post by zxiiro » Thu May 25, 2006 9:38 pm

Wow I wasn't aware you could set the shell to be non-shell programs. Interesting to know.
Top
kcbanner
n00b
n00b
Posts: 61
Joined: Tue Apr 04, 2006 3:44 am

  • Quote

Post by kcbanner » Fri May 26, 2006 2:54 am

Me neither...but then again, why not :P

Good to know
Sign the ATI Petition!: Here
Top
ChristyMcJesus
Apprentice
Apprentice
User avatar
Posts: 184
Joined: Sat Oct 02, 2004 5:02 pm

  • Quote

Post by ChristyMcJesus » Fri May 26, 2006 8:02 am

zxiiro wrote:Wow I wasn't aware you could set the shell to be non-shell programs. Interesting to know.
I've heard of people setting their login shell to emacs.
Desu DESU desu Desu Desu. Desu desu?
Top
Post Reply
  • Print view

8 posts • Page 1 of 1

Return to “Gamers & Players”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic