Skip to content

Instantly share code, notes, and snippets.

View concosminx's full-sized avatar

Cosmin Constantin concosminx

  • Pitesti, Romania
View GitHub Profile
@concosminx
concosminx / GitDeleteCommands.ps1
Created November 22, 2021 18:50 — forked from cmatskas/GitDeleteCommands.ps1
Git Delete Branch commands
## Delete a remote branch
$ git push origin --delete <branch> # Git version 1.7.0 or newer
$ git push origin :<branch> # Git versions older than 1.7.0
## Delete a local branch
$ git branch --delete <branch>
$ git branch -d <branch> # Shorter version
$ git branch -D <branch> # Force delete un-merged branches
## Delete a local remote-tracking branch
@concosminx
concosminx / server.conf
Created October 8, 2021 09:59 — forked from timcheadle/server.conf
SSL nginx config example
server {
listen 80;
server_name www.example.com example.com;
# Redirect all traffic to SSL
rewrite ^ https://$server_name$request_uri? permanent;
}
server {
listen 443 ssl default_server;
@concosminx
concosminx / docker_compose_cheatsheet.md
Created September 21, 2021 15:46 — forked from jonlabelle/docker_compose_cheatsheet.md
Docker Compose Cheatsheet
@concosminx
concosminx / gradle-cheatsheet.gradle
Created September 21, 2021 15:35 — forked from jahe/gradle-cheatsheet.gradle
Gradle Cheatsheet
// imports a couple of java tasks
apply plugin: "java"
// List available tasks in the shell
> gradle tasks
// A Closure that configures the sourceSets Task
// Sets the main folder as Source folder (where the compiler is looking up the .java files)
sourceSets {
main.java.srcDir "src/main"
NOTE:
Oracle9i: estimate_percent defaults to NULL which is COMPUTE
Oracle10g: estimate_percent defaults to to_estimate_percent_type (get_param('ESTIMATE_PERCENT'))
-- ********************************
-- * Generating Schema Statistics *
-- ********************************
execute dbms_stats.gather_schema_stats(ownname=>'SCHEMAOWNER',estimate_percent=>NULL,cascade=>TRUE,degree=>dbms_stats.default_degree)
execute dbms_stats.gather_schema_stats(ownname=>'SCHEMAOWNER',estimate_percent=>NULL,cascade=>TRUE,degree=>dbms_stats.default_degree,method_opt=>'FOR ALL INDEXED COLUMNS SIZE AUTO')
execute dbms_stats.gather_schema_stats(ownname=>'SCHEMAOWNER',estimate_percent=>NULL,cascade=>TRUE,degree=>dbms_stats.default_degree,method_opt=>'FOR ALL INDEXED COLUMNS SIZE 1') -- No Histograms
@concosminx
concosminx / README.md
Created June 8, 2021 07:27 — forked from leonardofed/README.md
A curated list of AWS resources to prepare for the AWS Certifications


A curated list of AWS resources to prepare for the AWS Certifications

A curated list of awesome AWS resources you need to prepare for the all 5 AWS Certifications. This gist will include: open source repos, blogs & blogposts, ebooks, PDF, whitepapers, video courses, free lecture, slides, sample test and many other resources.


@concosminx
concosminx / ssh.md
Created June 8, 2021 07:23 — forked from bradtraversy/ssh.md
SSH & DevOps Crash Course Snippets

SSH Cheat Sheet

This sheet goes along with this SSH YouTube tutorial

Login via SSH with password (LOCAL SERVER)

$ ssh [email protected]

Create folder, file, install Apache (Just messing around)

$ mkdir test

$ cd test

@concosminx
concosminx / jq-cheetsheet.md
Created June 8, 2021 07:01 — forked from olih/jq-cheetsheet.md
jq Cheet Sheet

Processing JSON using jq

jq is useful to slice, filter, map and transform structured json data.

Installing jq

On Mac OS

brew install jq

@concosminx
concosminx / redis_cheatsheet.bash
Created June 8, 2021 07:01 — forked from LeCoupa/redis_cheatsheet.bash
Redis Cheatsheet - Basic Commands You Must Know --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
# Redis Cheatsheet
# All the commands you need to know
redis-server /path/redis.conf # start redis with the related configuration file
redis-cli # opens a redis prompt
# Strings.