Category: Operating Systems

How to get the timezone in Ubuntu Linux?

If you are using a GNU/Linux distribution based on Ubuntu the easiest way to get the timezone is by using following command: timedatectl The output should look similar to this: Local time: Tue 2018-07-24 11:27:00 CDT Universal time: Tue 2018-07-24 16:27:00 UTC RTC time: n/a Time zone: America/Mexico_City (CDT, -0500) Network time on: yes NTP […]

Read More

How to Install Node.js on CentOS 7

The Problem Today, I was testing the new Angular 4 Scripting Application sample provided by IBM as a starting point for creating Script Portlet based Apps. However, my development environment is a CentOS 7 computer, and I usually don’t work with Node.js in that computer, so here the simple steps to install Node.js in a […]

Read More

Installing a Node.js App as a regular GNU/Linux process

While in development of any Node.js application we usually configure a npm start task to run it; but when you are ready to go to production that concept is not useful anymore. Until that moment, we have tested our application using the regular npm process (npm start); but now, we are going to need to go one […]

Read More

Delete files with a pattern recursively using the terminal

This is just a simple way to delete files recursively using your terminal in any UNIX-like operating system: find . -type f -name “FILES_PATTERN” -exec rm {} \; // Example find . -type f -name “*.mp3″ -exec rm {} \; Explanation -name “FILES_PATTERN” : File pattern. -exec rm -rf {} \; : Delete all files […]

Read More

Update Node.js using the terminal

These are just the steps to update Node.js by using your terminal: sudo npm cache clean -f sudo npm install -g n The n package represents a Node helper, and running this command upgrades node to the latest stable version. sudo n stable Just to confirm we can check our version: node -v // Output […]

Read More

My personal .gitignore file

Lesson learned After doing this file many times, I decided to build my personal .gitignore file; I use to add it in my very fist commit as a good practice in every single git repository I create. Currently we are ignoring: Operating systems’ temporary files: Mac OS X, GNU/Linux, Windows. IDEs and editors’ configuration: Vim, Sublime […]

Read More

How to do a “checkout” of a remote git branch

Let’s face it, everyone that loves technology, web development or any IT-related stuff works in teams, the old concept of a programmer/developer alone in his basement is not part of our life anymore, so; the usage of a version control system is a must. As you probably know, I am big fan of what I […]

Read More