summaryrefslogtreecommitdiffstats
path: root/profile.d/xhost.csh
diff options
context:
space:
mode:
Diffstat (limited to 'profile.d/xhost.csh')
-rwxr-xr-xprofile.d/xhost.csh11
1 files changed, 11 insertions, 0 deletions
diff --git a/profile.d/xhost.csh b/profile.d/xhost.csh
new file mode 100755
index 0000000..948e617
--- /dev/null
+++ b/profile.d/xhost.csh
@@ -0,0 +1,11 @@
+# Export Xauthority for users not for root.
+
+if ($?DISPLAY) then
+ if (! $?SSH_TTY) then
+ if ( `id -u` >= 14 ) then
+ if (! $?XAUTHORITY) then
+ setenv XAUTHORITY $HOME/.Xauthority
+ endif
+ endif
+ endif
+endif