-
-
Notifications
You must be signed in to change notification settings - Fork 20
/
Copy path.profile
58 lines (50 loc) · 1.83 KB
/
.profile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# .profile --- Initialisation script for display managers.
#
# Copyright (c) 2020-2023 Protesilaos Stavrou <[email protected]>
#
# This program is free software; you can redistribute it and/or
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
## Commentary:
#
# This script is read by a graphical display manager when logging into
# the session. It is conceptually similar to `.xinitrc' and I am
# considering it as practically equivalent to it for the ordinary
# functioning of my custom desktop session. Refer to my dotfiles for
# the specifics: https://github.com/protesilaos/dotfiles
###############
# Shell setup #
###############
# Source my bashrc.
if [ -n "$BASH_VERSION" ]; then
if [ -f "$HOME"/.bashrc ]; then
source "$HOME"/.bashrc
fi
fi
# Set PATH so it includes user's private executables.
if [ -d "$HOME"/.local/bin ]; then
PATH=$PATH:"$HOME"/.local/bin
fi
if [ -d "$HOME"/Builds/bin ]
then
PATH=$PATH:"$HOME"/Builds/bin
fi
##########################
# Environment essentials #
##########################
# Auto unlocks the GPG and SSH agents.
eval $(/usr/bin/gnome-keyring-daemon --start --components=pkcs11,secrets,ssh)
# export SSH_AUTH_SOCK
# TODO 2023-10-08: Why does this work on my laptop, but not the above?
# Is the desktop affected?
export SSH_AUTH_SOCK="/run/user/$(id -u)/gnupg/S.gpg-agent.ssh"