First steps with Go linters

Linter is a static code analysis tool used to find programming errors, bugs, leaks of code standards, and even security flaws. These tools help developers because they save time by identifying issues before they happen in the production environment. It also keeps developers from unnecessarily checking if your colleague used the team standards.

Each programming language has their own tools: Ruby has Rubocop , JS has Eslint , and Go can’t be different. Searching at Awesome Go , a curated list of Go software, many tools can lint your code, but my favorite is golangci-lint . It is an aggregator of linting tools, meaning you only need one tool for multiple linters in your project.

Introduction to templating with Go

Computer and programming languages were born to make our lives easier, as they automatize day-to-day tasks. Programmers and software engineers usually have to build files that are almost the same as others, where the only change is one field or another. For example, there are configuration files, invoices, XMLs, HTMLs or any file which we can use to build other files. There is a simple solution for this problem: we can create a template and change the parts that I need manually! That works, but it is not the best way to deal with the problem because it is scalable. We can use technology to help.

Introduction to Concurrency in Go

One of the best Go features is how easy we can use concurrency. The language gives us goroutines, which are like lightweight threads managed by the Go runtime. It help us to run several functions at the same instant and is very helpful if you wish to improve the performance of your application.

Using this feature is easy as adding the go keyword before any function call. This will make the function run concurrently. To make it simpler, let’s show you the code. Here I’ve written the SleepSort algorithm, which uses the sleep method to sort each element in its place.

RSA in Ruby for beginners

Introdução

RSA is a public/private encryption algorithm and it is based on the difficulty of the factorization of the product of two large prime numbers. It was named after its creators Rivest, Shamir, and Adleman.

It is an expensive algorithm, computationally speaking, and because of this, it is not common to use it directly, but it is still widely used in the market and is one of the most important encryption algorithms. As an example, OpenSSL implements this algorithm for generating keys and it is commonly used for encrypting SSL certificates or SSH keys.