It is a partial excerpt of the following article and + α.
I learned Rust from 0 ~ Part.0 Preparation / Overview ~ --Yuto Hongo Portfolio
It is assumed that the Rust compiler has been installed and the path has been set for use on a Mac.
bash:.bashrc and.bash_profile etc.
#!/bin/sh
rust(){
rustc $1 --out-dir `dirname $1` | `echo $1 | sed 's/\.[^\.]*$//'`
}
% rust path/sample.rs
I feel like it's not good, but once it's like this. .. ..
CodeRunner – Programming Editor for macOS
Introducing the settings with this tool.
RunCommand
rustc $filename | ./$compiler
Click the execute button