Skip to content
Snippets Groups Projects
script.sh.erb 881 B
Newer Older
#!/bin/bash -l
Matthew K Defenderfer's avatar
Matthew K Defenderfer committed

# Set working directory to home directory
cd "${HOME}"

module reset

#
# Launch Xfce Window Manager and Panel
#

Matthew K Defenderfer's avatar
Matthew K Defenderfer committed
(
  export SEND_256_COLORS_TO_REMOTE=1
  export XDG_CONFIG_HOME="<%= session.staged_root.join("config") %>"
  export XDG_DATA_HOME="<%= session.staged_root.join("share") %>"
  export XDG_CACHE_HOME="$(mktemp -d)"
  set -x
  xfwm4 --compositor=off --daemon --sm-client-disable
  xsetroot -solid "#D3D3D3"
  xfsettingsd --sm-client-disable
  xfce4-panel --sm-client-disable
) &
Matthew K Defenderfer's avatar
Matthew K Defenderfer committed

#
# Start Pycharm
#

export SINGULARITY_BINDPATH='/data,/scratch,/local,/share'

# Load git as the OS versions are too old
module load git/2.41.0-GCCcore-12.3.0-nodocs 

# Load Anaconda3
module load Anaconda3

# List loaded modules
module list

# Launch PyCharm
set -x
singularity exec <%= context.extra_singularity_args %> \
    <%= context.container_path %> \
    pycharm