How to give someone your code to run

Perhaps this deserves a thread of its own. Here is a really simple solution to the problem how to give someone your code to run.

Visit GitHub - PetrKryslUCSD/FreeVibrationExample: Simple Example of Free Vibration Computation and follow the instructions. (Really simple: just download the repo and double click a batch file. Windows only at the moment, sorry.)

Some notes:

  1. This workflow (GitHub - PetrKryslUCSD/FreeVibrationExample: Simple Example of Free Vibration Computation) is only needed if the person receiving the instructions does not have an installed Julia at all.
  2. To adjust this workflow for a different application project it doesn’t take more than changing a single variable: FreeVibrationExample/install.sh at 8be88c2e9687c3629fe71890d90407bfaa8699a8 · PetrKryslUCSD/FreeVibrationExample · GitHub
    No other messing with batch files is required. In a pinch, the user package name could be solicited
    from the user at runtime.
  3. If the person receiving the program already has Julia installed, all that is needed is to download
    GitHub - PetrKryslUCSD/RunVibrationExample.jl: Run an example of a free-vibration solution and run run.jl in that folder. That is a pure Julia workflow. In doesn’t take more than say include("run.jl").
14 Likes

Is there a way to give my source code to run by someone who is not familiar with programming?
He does not need any IDE like vscode, just a portable julia binaries with packages.

I mean, something like a relocatable app, made by PackageCompiler.create_app but with no need to compile it - just make a relocatable source code?

I’m asking, because in some cases PacakgeCompiler introduces problems with deps that have some untracked artifacts or environment states. (It’s easy to instantiate and build packages, but hard to compile them into a relocatable app.)

2 Likes

A simple modification of the installation script could omit the installation of the editor and instead run a specified file in Julia. That is not a problem.

2 Likes