slackware ignora .bashrc e bash_profile?

Se avete problemi con l'installazione e la configurazione di Slackware postate qui. Non usate questo forum per argomenti generali... per quelli usate Gnu/Linux in genere.

Moderatore: Staff

Regole del forum
1) Citare sempre la versione di Slackware usata, la versione del Kernel e magari anche la versione della libreria coinvolta. Questi dati aiutano le persone che possono rispondere.
2) Per evitare confusione prego inserire in questo forum solo topic che riguardano appunto Slackware, se l'argomento è generale usate il forum Gnu/Linux in genere.
3) Leggere attentamente le risposte ricevute.
4) Scrivere i messaggi con il colore di default, evitare altri colori.
5) Scrivere in Italiano o in Inglese, se possibile grammaticalmente corretto, evitate stili di scrittura poco chiari, quindi nessuna abbreviazione tipo telegramma o scrittura stile SMS o CHAT.
6) Appena registrati è consigliato presentarsi nel forum dedicato.

La non osservanza delle regole porta a provvedimenti di vari tipo da parte dello staff, in particolare la non osservanza della regola 5 porta alla cancellazione del post e alla segnalazione dell'utente. In caso di recidività l'utente rischia il ban temporaneo.
Rispondi
Almucantarat
Linux 1.x
Linux 1.x
Messaggi: 132
Iscritto il: ven 15 apr 2005, 0:00

slackware ignora .bashrc e bash_profile?

Messaggio da Almucantarat »

ciao a tutti sono appena passato a slackware 10.1 con xfce
<BR>
<BR>non trovando il file .bashrc nella home l´ho creato ma all´avvio non viene letto.
<BR>stessa cosa per bash_profile
<BR>
<BR>dove sbaglio?<br>

gianPrazio
Linux 2.x
Linux 2.x
Messaggi: 388
Iscritto il: mer 29 set 2004, 0:00
Località: Castelfranco Veneto

slackware ignora .bashrc e bash_profile?

Messaggio da gianPrazio »

Ciao!
<BR>Non so se sia il modo corretto per farlo, comunque prova
<BR>1) a rendere eseguibile .bashrc ("chmod +x .bashrc");
<BR>
<BR>2) ad aggiungere alla fine di /etc/profile le seguenti righe:
<BR><!-- BBCode Start --><TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font size=-1>Code:</font><HR></TD></TR><TR><TD><FONT SIZE=-1><PRE>
<BR>if [ -x $HOME/.bashrc ]; then
<BR> . $HOME/.bashrc
<BR>fi
<BR></PRE></FONT></TD></TR><TR><TD><HR></TD></TR></TABLE><!-- BBCode End -->
<BR>
<BR>Ho trovato la possibile soluzione googlando un po´ e arrivando a questo sito:
<BR><a href="http://www.cygwin.com/ml/cygwin/2005-02 ... 57.html</a>
<BR>Fammi sapere se riesci a combinare qualcosa!<br>

samiel
Staff
Staff
Messaggi: 5511
Iscritto il: ven 16 gen 2004, 0:00
Nome Cognome: Mauro Sacchetto
Slackware: 13.0
Kernel: 2.26
Desktop: KDE
Distribuzione: anche Debian
Località: Venezia

slackware ignora .bashrc e bash_profile?

Messaggio da samiel »

Rendere eseguibile .bashrc è inutile,
<BR>perché è un file di configurazione (cioè
<BR>di lettura), non un eseguibile.
<BR>Prova invece ad aggiungere alla fine di /etc/profile
<BR>una stringa come questa:
<BR>
<BR>if [ -f ~/.bashrc ]; then
<BR> source ~/.bashrc
<BR>fi
<BR>
<BR>M.
<BR><br>

Avatar utente
scorpion77
Linux 1.x
Linux 1.x
Messaggi: 102
Iscritto il: gio 20 gen 2005, 0:00
Nome Cognome: Andrea
Slackware: Slackware64 14.1
Desktop: KDE 4.10.5

slackware ignora .bashrc e bash_profile?

Messaggio da scorpion77 »

A me funziona benissimo. Fai un collegamento simbolico a .bashrc in questo modo:
<BR>
<BR><!-- BBCode Start --><B>ln -s .bashrc .bash_profile</B><!-- BBCode End -->
<BR>
<BR>
<BR>Scorpion77<br>

Almucantarat
Linux 1.x
Linux 1.x
Messaggi: 132
Iscritto il: ven 15 apr 2005, 0:00

slackware ignora .bashrc e bash_profile?

Messaggio da Almucantarat »

grazie a tutti, ora funziona!
<BR>però ho scoperto un altro problema: all´avvio X non fa il source di /etc/profile
<BR>
<BR>cioè:
<BR>* faccio il login e arrivo in modalità testo.Lì funziona tutto.
<BR>* scrivo startx, parte xfce e non ho più i settaggi di /etc/profile
<BR>
<BR><br>

samiel
Staff
Staff
Messaggi: 5511
Iscritto il: ven 16 gen 2004, 0:00
Nome Cognome: Mauro Sacchetto
Slackware: 13.0
Kernel: 2.26
Desktop: KDE
Distribuzione: anche Debian
Località: Venezia

slackware ignora .bashrc e bash_profile?

Messaggio da samiel »

<!-- BBCode Quote Start --><TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font size=-1>Quote:</font><HR></TD></TR><TR><TD><FONT SIZE=-1><BLOCKQUOTE> A me funziona benissimo. Fai un collegamento simbolico a .bashrc in questo modo: ln -s .bashrc .bash_profile </BLOCKQUOTE></FONT></TD></TR><TR><TD><HR></TD></TR></TABLE><!-- BBCode Quote End -->
<BR>
<BR>Puoi postare il contenuto dei tuoi due file?
<BR>
<BR>Grazie
<BR>M.<br>

Almucantarat
Linux 1.x
Linux 1.x
Messaggi: 132
Iscritto il: ven 15 apr 2005, 0:00

slackware ignora .bashrc e bash_profile?

Messaggio da Almucantarat »

sia .bashrc che .bash_profile mancavano,li ho dovuti creare io,quindi a parte una variabile esportata che ho settato io, sono perfettamente vuoti
<BR>
<BR>ho aggiustato parzialmente la faccenda di xterm copiando uno script (che doveva rendere + bello xterm :) ) e dandogli il nome .Xresources
<BR>
<BR>ora sto cercando di dare a xterm una barra di scroll....:( idee?
<BR>
<BR>ora mi chiedo...sta capitando solo a me o è prassi comune di tutte le istallazioni slackware?<br>

Avatar utente
gallows
Staff
Staff
Messaggi: 3471
Iscritto il: lun 20 set 2004, 0:00
Desktop: cwm
Distribuzione: OpenBSD
Località: ~/
Contatta:

slackware ignora .bashrc e bash_profile?

Messaggio da gallows »

xterm -sb
<BR>
<BR>ma come fai a dire che .bashrc non é letto se é vuoto?<br>

Almucantarat
Linux 1.x
Linux 1.x
Messaggi: 132
Iscritto il: ven 15 apr 2005, 0:00

slackware ignora .bashrc e bash_profile?

Messaggio da Almucantarat »

allora:
<BR>ho creato .bashrc e dentro vi ho scritto export AUGER_BASE=/home/amir/auger
<BR>
<BR>non veniva letto (echo $AUGER_BASE) anche aprendo un altro xterm.
<BR>
<BR>ho aggiunto lo script di Samiel in /etc/profile.
<BR>veniva letto,ma tutti i settaggi relativi a xterm no (ad esempio, la bash mostrava solo bash-3.00#> invece di <a href="mailto:amir@localhost" target="_new">amir@localhost</a>:~> )
<BR>
<BR>ora ho "creato" .Xresources e prende tutti i settaggi di xterm.
<BR>
<BR>grazie a te ora ho anche la barra :-D <br>

samiel
Staff
Staff
Messaggi: 5511
Iscritto il: ven 16 gen 2004, 0:00
Nome Cognome: Mauro Sacchetto
Slackware: 13.0
Kernel: 2.26
Desktop: KDE
Distribuzione: anche Debian
Località: Venezia

slackware ignora .bashrc e bash_profile?

Messaggio da samiel »

-----------------------------------------------
<BR>sia .bashrc che .bash_profile mancavano
<BR>-----------------------------------------------
<BR>
<BR>Non è che "mancavano", è che Slackware
<BR>crea solo /etc/profile e poi devi fare da te
<BR>se vuoi personalizzare la shell.
<BR>
<BR>M.<br>

Almucantarat
Linux 1.x
Linux 1.x
Messaggi: 132
Iscritto il: ven 15 apr 2005, 0:00

slackware ignora .bashrc e bash_profile?

Messaggio da Almucantarat »

ahhh ecco!
<BR>
<BR>ultime cose: non riesco a far funzionare il network time protocol per aggiustare l´orologio, e non riesco a trovare niente a proposito in rete
<BR><BR><BR>[ Questo Messaggio è stato Modificato da: Almucantarat il 16-04-2005 15:49 ]<br>

Avatar utente
scorpion77
Linux 1.x
Linux 1.x
Messaggi: 102
Iscritto il: gio 20 gen 2005, 0:00
Nome Cognome: Andrea
Slackware: Slackware64 14.1
Desktop: KDE 4.10.5

slackware ignora .bashrc e bash_profile?

Messaggio da scorpion77 »

<!-- BBCode Quote Start --><TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font size=-1>Quote:</font><HR></TD></TR><TR><TD><FONT SIZE=-1><BLOCKQUOTE>
<BR> 16-04-2005 alle ore 14:50, samiel :
<BR><!-- BBCode Quote Start --><TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font size=-1>Quote:</font><HR></TD></TR><TR><TD><FONT SIZE=-1><BLOCKQUOTE> A me funziona benissimo. Fai un collegamento simbolico a .bashrc in questo modo: ln -s .bashrc .bash_profile </BLOCKQUOTE></FONT></TD></TR><TR><TD><HR></TD></TR></TABLE><!-- BBCode Quote End -->
<BR>
<BR>Puoi postare il contenuto dei tuoi due file?
<BR>
<BR>Grazie
<BR>M.<br>
<BR></BLOCKQUOTE></FONT></TD></TR><TR><TD><HR></TD></TR></TABLE><!-- BBCode Quote End -->
<BR>
<BR>Ecco il contenuto di .bashrc (.bash_profile è un link simbolico ad esso):
<BR>
<BR><!-- BBCode Start --><B>
<BR>PATH="/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:$HOME:/usr/local/sbin:/usr/sbin:/sbin"
<BR>
<BR># If the user doesn´t have a .inputrc, use the one in /etc.
<BR>if [ ! -r "$HOME/.inputrc" ]; then
<BR> export INPUTRC=/etc/inputrc
<BR>fi
<BR>
<BR># I had problems using ´eval tset´ instead of ´TERM=´, but you might want to
<BR># try it anyway. I think with the right /etc/termcap it would work great.
<BR># eval `tset -sQ "$TERM"`
<BR>if [ "$TERM" = "" -o "$TERM" = "unknown" ]; then
<BR> TERM=linux
<BR>fi
<BR>
<BR># Set ksh93 visual editing mode:
<BR>if [ "$SHELL" = "/bin/ksh" ]; then
<BR> VISUAL=emacs
<BR># VISUAL=gmacs
<BR># VISUAL=vi
<BR>fi
<BR>
<BR># Set a default shell prompt:
<BR>#PS1=´`hostname`:`pwd`# ´
<BR>if [ "$SHELL" = "/bin/pdksh" ]; then
<BR> PS1=´! $ ´
<BR>elif [ "$SHELL" = "/bin/ksh" ]; then
<BR> PS1=´! ${PWD/#$HOME/~}$ ´
<BR>elif [ "$SHELL" = "/bin/zsh" ]; then
<BR> PS1=´%n@%m:%~%# ´
<BR>elif [ "$SHELL" = "/bin/ash" ]; then
<BR> PS1=´$ ´
<BR>else
<BR> PS1=´\u@\h:\w\$ ´
<BR>fi
<BR>PS2=´> ´
<BR>export PATH DISPLAY LESS TERM PS1 PS2
<BR>
<BR># Default umask. A umask of 022 prevents new files from being created group
<BR># and world writable.
<BR>umask 022
<BR>
<BR># Set up the LS_COLORS and LS_OPTIONS environment variables for color ls:
<BR>if [ "$SHELL" = "/bin/zsh" ]; then
<BR> eval `dircolors -z`
<BR>elif [ "$SHELL" = "/bin/ash" ]; then
<BR> eval `dircolors -s`
<BR>else
<BR> eval `dircolors -b`
<BR>fi
<BR>
<BR># Notify user of incoming mail. This can be overridden in the user´s
<BR># local startup file (~/.bash.login or whatever, depending on the shell)
<BR>if [ -x /usr/bin/biff ]; then
<BR> biff y
<BR>fi
<BR>
<BR># Append any additional sh scripts found in /etc/profile.d/:
<BR>for profile_script in /etc/profile.d/*.sh ; do
<BR> if [ -x $profile_script ]; then
<BR> . $profile_script
<BR> fi
<BR>done
<BR>unset profile_script
<BR>
<BR>
<BR>alias mount=´sudo /sbin/mount´
<BR>alias umount=´sudo /sbin/umount´
<BR>alias eject=´sudo /usr/bin/eject´
<BR>alias pkgtool=´sudo pkgtool´
<BR>alias reboot=´sudo /sbin/reboot´
<BR>alias shutdown=´sudo /sbin/shutdown´
<BR>alias halt=´sudo /sbin/halt´
<BR>alias poweroff=´sudo /sbin/poweroff´
<BR></B><!-- BBCode End -->
<BR>
<BR>
<BR>Scorpion77<br>

Rispondi