This commit is contained in:
zer 2024-07-06 21:04:33 -07:00
commit db06c534ab
2 changed files with 39 additions and 0 deletions

39
README.md Normal file
View File

@ -0,0 +1,39 @@
# Ruby_Blog
This is the supporting repo for the corresponding blog that can be found [here](https://bgsysadmin.site/posts/Docs/ "Docs")
### Below is the blog in full as well
![header](/ruby-header-chad-peltola.png "Original Image by, Chad Peltola(Final edits by BCG)")
Changing everything about a project or making it your own could depend on the documentation. Other times, you may need to write this documentation down for your own future use. Today we will start with some documentation related to installing *Ruby* for later use relating to *Jekyll*. So let's start with installing *Ruby*.
They have package managers and all kinds of installation methods. But we will go with one of the best, most failsafe ways to install *Ruby* with duplicatable results. No matter the operating system, let's install *Ruby* from source. Always go straight to the source of the software. An organization website or an official git repo. Let us begin with setting the path so your *GEMs* work properly.
```shell
echo 'export GEM_HOME="$HOME/gems"' >> ~/.bashrc
echo 'export PATH="$HOME/gems/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc
```
Now that we have defind our *GEM* path, we can move on to downloading the software and installation. You can download the source to any location you wish, perhaps something like *.local*. I am going to use *.config*.
```shell
cd .config
wget https://cache.ruby-lang.org/pub/ruby/3.3/ruby-3.3.1.tar.gz
```
Now the verion is going to change over time. So update the verion as needed [here](https://www.ruby-lang.org/en/downloads/ "Ruby Downloads"). If you don't have wget, use your package manager to install that.
```shell
tar -xvzf ruby-3.3.1.tar.gz
sudo rm -r ruby-3.3.1.tar.gz
cd ruby-3.3.1
```
Now let's build the source out.
```shell
cd ruby-3.3.1
./configure
make
sudo make install
```
You will see some prompts. You can see we are using the *./configure* script then running *make* and respectively *sudo make install*. This will take care of the process. The reason I decided to use source is that it's consistant. When you rely on it working for *Jekyll*, I ran into issues. I run *ARCH* by the way.
Guess what? They break up the *GEM* installation in a way that breaks the functionality, this took some searching. It is not known to me if it's a security privilege sort of thing or a development flow. But, it's not ok for the end user. This setup will work on *ARCH*, just incase you are like me. For installation on other systems, your path may differ, as well as initial script used. So make sure to read the original documentation for any changes.

Binary file not shown.

After

Width:  |  Height:  |  Size: 918 KiB