gitpod-io / gitpod-io/gitpod

Using dotfiles to Append to ~/.bashrc Causes Workspace to Stop Immediately After Starting When VS Code Desktop Is Selected

Open
#13,846 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

aspect: browser IDE aspect: desktop IDE aspect: error-handling aspect: gitpod loading process feature: dotfiles meta: never-stale type: bug
Dominant language
TypeScript
Stars
13.8k
Forks
1.4k
Avg merge
17h 58m
Merged PRs (30d)
5

Description

Bug description

When using the dotfiles feature AND attempting to add a new file into $HOME/.bashrc.d/ OR appending to $HOME/.bashrc AND having your IDE preference selected to VS Code Desktop, the workspace is unable to start up. The workspace seems to go through the Initializing Content step, but then stops.

This video shows me trying to start a workspace with VS Code Desktop selected under Settings > Preferences:

https://www.loom.com/share/f45019e94b2a48cab4c063e2a96563a1

This video shows me trying to start a workspace with VS Code Browser selected:

https://www.loom.com/share/f2ca8c85d0d04162958ebb111e3fa95d

As you can see in the former video the workspace just stops. The later video shows the workspace coming up in my web browser.

Steps to reproduce
  1. Create a new repository on GitHub.
  2. Within your new repository create a file install.sh with the following content:
    #!/bin/bash
    
    brew install starship
    echo 'eval "$(starship init bash)"' >> $HOME/.bashrc
    
  3. Make sure to make your install.sh file executable (ex. chmod +x ./install.sh).
  4. Go to https://gitpod.io/preferences and select VS Code as your IDE.
  5. Scroll down and input the URL of your new dotfiles repo into the 'Repository URL' under the Dotfiles section.
  6. Click on the 'Save Changes' button.
  7. Now navigate to https://gitpod.io/workspaces and open a new workspace.
  8. Observe the workspace starting up and then stopping.
Workspace affected

No response

Expected behavior

I would expect that the workspace start up and prompt me to open in VS Code and if it fails too tell me why it's not and instead stopping.

Example repository

You can use my dotfiles repo if you'd like - https://github.com/jimmybrancaccio/starship-dotfiles/blob/main/install.sh

This is the test repo I am using to create my workspace from - https://github.com/jimmybrancaccio/gitpod-test

Anything else?

No response

Front logo Front conversations

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure with the provided install.sh, which appends Starship initialization to $HOME/.bashrc, and compare VS Code Desktop with VS Code Browser. Review the dotfiles startup path and the behavior around $HOME/.bashrc.d/, using the linked example repositories and videos as references. Done means the workspace starts in VS Code Desktop or reports a useful failure instead of stopping silently.

Written by the indexing model from the issue text.

Assessment

Tech stack
bash, typescript, vscode
Domain
cloud, desktop, developer-experience, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.