Last Updated on September 15, 2020 by Christopher G Mendla
I needed a way to show the status (Up/down) of internal Ruby applications. I found an answer on StackOverflow that pointed me in the right direction (Apologies that I can’t locate that post). . I modified that somewhat by putting it into a method and passing the site name to it.
If you are using form tags in a ruby view, they need to be outside of any table elements or the form/submit button will not work properly.
Last Updated on September 3, 2020 by Christopher G Mendla
I needed to validate CSV files that were being imported into a Rails app. The validation was simple: Look for blank entries, ensure columns used for associations (IDs) were integers and check that certain other entries were numeric.
The first thing I checked was to make sure that the header of the CSV file matched what we expected. The simplest way to do this was to set an ‘expected header’ and then check the header on the CSV.
Last Updated on September 2, 2020 by Christopher G Mendla
Whenever you update your Rails version, you should always use Railsdiff.org. The importance of this cannot be overstated. Railsdiff will provide a list of ALL of the changes required to your rails code.
Last Updated on August 27, 2020 by Christopher G Mendla
When trying to update a virtual machine running Ubuntu 18 on a Windows 10 machine I kept running into failures. I thought I’d just go to a fresh install of Ubuntu 20.04 and rebuild my Ruby on Rails development environment. That also failed. I found that the culprit that Docker was running on Windows 10 and there are conflicts between Hyper-V and Virtualbox.
Last Updated on August 26, 2020 by Christopher G Mendla
Using outdated gems in your Ruby on Rails application introduces vulnerabilities to your Rails Applications. There is an easy way to find outdated gems using the Bundle Outdated command.
Last Updated on January 19, 2020 by Christopher G Mendla
You have to be kidding me.. I just found out that Active Storage in Rails DOES NOT SUPPORT VALIDATIONS.
Determining the exact version of Linux you are running is fairly simple. Use this command to find your Linux version.
Last Updated on January 17, 2020 by Christopher G Mendla
THIS was driving me batty. I have Putty running on Ubuntu which runs on an Oracle Virtualbox on a Win 10 machine. I was trying to copy and paste and getting nowhere. The solution turned out to be pretty simple