Συντονιστής: adem1
:~$ cat .profile
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile
umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d ~/bin ] ; then
PATH=~/bin:"${PATH}"
fi
sudo nano /home/NAMEOFUSER/.profile
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile
#umask 022 //αφαίρεσε τη δίεση
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="$HOME/bin:$PATH"
fi
atermon έγραψε:Τρέξε
- Κώδικας: Επιλογή όλων
sudo nano /home/NAMEOFUSER/.profile
- Κώδικας: Επιλογή όλων
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile
#umask 022 //αφαίρεσε τη δίεση
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="$HOME/bin:$PATH"
fi
The_Mentor έγραψε:η umask ξεκινώντας έχει σαν default value την 022 η οποία σε κάθε αρχείο που δημιουργείται δίνει δικαιώματα 0666 & ~022 = 0644 = rw-r--r--
Αν θέλεις να δώσεις πρόσβαση στα αρχεία που δημιουργείς ή μετακινείς από ntfs partition πρέπει να τις ορίσεις τη τιμή 002 άρα πρεπει να κάνεις edit το αρχείο /etc/profile (όπως βλέπεις παρακάτω).
- Κώδικας: Επιλογή όλων
:~$ cat .profile
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile
umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d ~/bin ] ; then
PATH=~/bin:"${PATH}"
fi
BTW, κυκλοφορεί και ένα bug για την umask, δες εδώ
.
.
The_Mentor έγραψε:το .profile είναι κρυφό αρχείο. Άνοιξε το home folder σου στον nautilus και πάτα CTRL+H για να εμφανίσει τα κρυφά αρχεία. Κάπου κάτω θα το δεις. Ανοιξέ το με έναν editor και άλλαξε το umask.
Κάνε τα παραπάνω με δικαιώματα root