Skip to content

Instantly share code, notes, and snippets.

@somecuitears
somecuitears / log4j properties.md
Last active March 27, 2017 10:29
Log4J properties

Log4J

To show the log in both console and file create log4j.properties file on scr folder then paste the following code inside the properties file.

log4j.rootLogger=DEBUG,console, FILE
log4j.appender.FILE=org.apache.log4j.FileAppender    
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.layout=org.apache.log4j.PatternLayout
log4j.appender.console.Target=System.out
@somecuitears
somecuitears / git.md
Last active March 27, 2017 10:28
Git Basics

Git Basics

Initialize git repository on folder of project

git init

Check current status of projects i.e. files added to project folder

git status
@somecuitears
somecuitears / homebrew.md
Created February 9, 2017 15:44
Homebrew and UPX Installation Procedure for macOS

UPX detail : Compress/expand executable files;

Open terminal | Command+Space and type Terminal and press enter/return key.

Paste following code :

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" < /dev/null 2> /dev/null
@somecuitears
somecuitears / git-ssh-configuration.md
Created February 9, 2017 15:47 — forked from cham11ng/git-ssh-configuration.md
Configuring SSH for Git

Git Installation and SSH Configuration

By: Sagar Chamling

Installation

For Linux (Debian/Ubuntu):

sudo apt install git
@somecuitears
somecuitears / macOS.md
Last active April 3, 2017 04:58
Usefull macOS tweaks

Hidden Files and Folders

Open terminal and paste following codes to:

Hide files or folder

chflags hidden <file/folder>

Show Hidden files and folders

@somecuitears
somecuitears / Spring.md
Last active May 9, 2017 04:03
Spring on Idea IntelliJ Ultimate

Create Basic Spring MVC Project

  1. Create New Project

  2. Select Spring Framework and check the Spring MVC and JavaEE Web application

  3. Find web.xml and change

<url-pattern>*.form</url-pattern>
@somecuitears
somecuitears / chocolate.md
Last active March 27, 2017 10:23
Package manager for windows

Installing Chocolatey

  1. Open Powershell in admin mode from start menu.
  2. Allow running sript on powershell using following code
Set-ExecutionPolicy RemoteSigned
  1. Type YES and press enter.
  2. Paste following code to begin installing Chocolatey
@somecuitears
somecuitears / gradle installation.md
Last active March 27, 2017 10:21
Gradle Installation
@somecuitears
somecuitears / Gradle SpringMVC.md
Last active January 27, 2020 16:05
Spring MVC from Gradle in IntelliJ

Creating Gradle Project

  1. Create New Project

  2. Select Java and Web from the Option

  3. You will be asked to provide GroupID and ArtifactID

  • GroupID: it will identify your project uniquely across all projects. (E.g. com.project.model | com.project.plugins)
@somecuitears
somecuitears / springboot.md
Last active May 8, 2017 12:40
Spring Boot in IntelliJ

Spring Boot

  1. Create New Project > Spring Initializer
  2. Set Initializer Service URL to https://start.spring.io
  3. Enter Group, Artifact and Type -> Gradle Project
  4. Select Required Dependencies
    • AOP
    • Web
    • JDBC
    • JPA
  5. Import Module dialog will appear check auto-import, use default gradle wrapper then click ok