Skip to content

Latest commit

 

History

History
64 lines (42 loc) · 2.2 KB

File metadata and controls

64 lines (42 loc) · 2.2 KB

playnite-web-appDocs


playnite-web-app / contributing/development-environment/codespaces

Developer Environment: Code Space/DevContainer

Required Software

Install the following software on your local machine:

  1. vscode
  2. XServer (for running Cypress tests).
    • For OSX, recommend: XQuartz
    • For Windows, still need a recommendation.
  3. gh CLI

Setup X11 Forwarding

Enable X11 Forwarding for SSH

First, enable X11 forwarding for your SSH configuration by editing ~/.ssh/config.

Host *
  ForwardX11 yes

Configuring an XServer

Once an XServer is installed, such as XQuartz, ensure it is configured to Authenticate and Allow connections from network clients. This can be done via the security settings of XQuartz.

Also ensure XQuartz starts at login.

Finally, sign out completely and sign back in.

Allowing Connections to XServer

Next, allow connections from your host machine's IP address. Here is an example is bash:

IP=$(ifconfig en0 | grep inet | awk '$1=="inet" {print $2}')

xhost + $IP
# If xhost is not found, try:
/usr/X11/bin/xhost + $IP

Preparing Codebase

  1. Fork the playnite-web repo
  2. Start a code space and open in vscode.
  3. Run yarn
  4. Run yarn nx run playnite-web-app:start
  5. In vscode, forward port 3000. This can be found in same pane as the terminal.
  6. Open http://localhost:3000.
  7. Continue to see commands for additional commands.

Running Component/E2E Tests

  1. Open terminal on local machine.
  2. Connect to code space via gh CLI and forward x11 via gh cs ssh -- -XY and then choose your code space.
  3. You can now run yarn nx run playnite-web-app:test/components and yarn nx run playnite-web-app:test/e2e in this terminal.