Last active
August 11, 2024 13:24
-
-
Save benjaminjackman/9d2284dff3e5098a2df0 to your computer and use it in GitHub Desktop.
Instructions on how to open Unity3d scripts in Rider on Ubuntu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Simple instructions for using Unity3d with project rider on Ubuntu | |
#1. Download and install latest .deb for Unity3d from: | |
http://forum.unity3d.com/threads/unity-on-linux-release-notes-and-known-issues.350256/ | |
#2. Download and install the Project Rider EAP (not sure if publicly available but you | |
can sign up for early access here: https://www.jetbrains.com/rider/ | |
#3. Open the Unity3d (.deb installs the executable at /opt/Unity/Editor/Unity ) | |
#4. Create a Project in Unity | |
#5. Start rider and open the .sln file for the project you made in Unity3d | |
#6. Rider should have made a script on your system on the first start to start itself called `rider`, | |
it needs to be in your PATH for this to work | |
#7. Save the rider-for-unity.sh script below. It will act as a bridge between Unity3d and rider | |
that reformats the commandline arguments so that rider can understand them | |
(you need to save it and make it executable) | |
#8. In Unity3d, under Edit > Preferences > External tools | |
a. Select the rider-for-unity script as the External Script Editory | |
b. Set | |
"$(File)" $(Line) | |
as the External Script Editor Args | |
#Scripts should now open in unity |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Select this script and add | |
#"$(FILE)" $(LINE) | |
#as the argument in unity preferences for the external script editor | |
#For some reason everything get's passed as one big blob of an argument | |
#so this will separate it into a FILEname and LINE number | |
FILE=$(echo $* | sed 's/"\(.*\)" .*/\1/') | |
LINE=$(echo $* | sed 's/".*" \(.*\)/\1/') | |
rider -l $LINE $FILE |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is it fine, if I leave this link here?
https://github.com/JetBrains/Unity3dRider
Just add it to your Unity solution, point to Rider executable and you have the integration. Works everywhere, including Ubuntu.