Skip to content

Instantly share code, notes, and snippets.

View johnatanbrayan's full-sized avatar
🏠
Working from home

Johnatan Brayan johnatanbrayan

🏠
Working from home
View GitHub Profile
@johnatanbrayan
johnatanbrayan / hashCodeAndEqual1.java
Last active March 9, 2022 00:42
How to create a hashCode and Equals
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Entity entity = (Entity) o;
if (entity.getId() == null || getId() == null) {
@johnatanbrayan
johnatanbrayan / best_database_diagram_design_tools.txt
Last active April 14, 2021 01:29
Best Database Diagram Design Tools
## Best Database Diagram Design Tools:
https://dbdiagram.io/home?utm_source=holistics&utm_medium=top_5_tools_blog
https://www.quickdatabasediagrams.com/
https://dbmstools.com/tools/sqldbm.com
https://sqldbm.com/Home/
@johnatanbrayan
johnatanbrayan / heroku
Last active March 30, 2021 15:31
Command to execute java on heroku
java $JAVA_OPTS -Xmx256m -jar target/*.jar --spring.profiles.active=prod,heroku,api-docs
@johnatanbrayan
johnatanbrayan / 1-how_to_configure_and_integrate_spring_boot_and_angular.txt
Last active March 18, 2021 04:04
How to configure and integrate spring boot and angular
# Commands of project:
./mvnw clean install
./mvnw spring-boot:run
# The project need:
- JDK 11
- Node v14.16.0
- NPM 6.14.11
@johnatanbrayan
johnatanbrayan / how_to_install_tomcat9_on_linux.txt
Created March 12, 2021 14:43
How to install and configure tomcat9 on Linux
Link to tutorial: https://www.journaldev.com/39819/install-tomcat-on-linux
## Commands:
sudo systemctl daemon-reload
sudo systemctl start tomcat
sudo systemctl status tomcat
# To see logs of service
@johnatanbrayan
johnatanbrayan / launch_vscode.json
Last active October 4, 2021 18:49
Configuration of Launch on Vscode
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Spring Boot-ProjectNameApp<projectName>",
"request": "launch",
@johnatanbrayan
johnatanbrayan / increase_memory_swap.txt
Created March 3, 2021 14:56
How to increase Memory Swap in Linux
# See Parameters:
swapon --show
ls -l /swapfile
free -h
# Unmont memory swap
swapoff /swapfile
# Set new size memory on swap; 8G is the new size of memory
fallocate -l 8G /swapfile
@johnatanbrayan
johnatanbrayan / 01_eslint_prettier_editorconfig.md
Last active April 14, 2021 02:23
Tutorial to install and configure EsLint, Prettier and EditorConfig on projects.

How to install and setting EsLint, Prettier and EditorConfig on projects.

  • Eslint: A bug pointer. It is a static code analysis tool to identify problematic patterns found in the javascript code.

  • Prettier: Responsible for formatting. Imposes a consistent code style across the base code, responsible for making our code beautiful.

  • EditorConfig: Facilitates code style adoption and standardization for multiple editors and IDEs.

@johnatanbrayan
johnatanbrayan / Guide to react and component react
Created December 20, 2020 20:51
Guide to react and component react
# Create project react
npx create-react-app name-project // or npx create-react-app name-project --template typescript
# Install component threejs on react
yarn add three react-three-fiber drei sass react-spring
@johnatanbrayan
johnatanbrayan / Commands Jhipster
Last active December 21, 2020 22:05
Commands on terminal Jhipster
# How to install
npm install -g generator-jhipster
# Create a aplication
jhipster
# Create entity by termial
jhipster entity <entityName>
# Create entity by archive .jh