Skip to content

Instantly share code, notes, and snippets.

View Aracki's full-sized avatar
🇷🇸

Ivan Aracki Aracki

🇷🇸
View GitHub Profile
@Aracki
Aracki / .bash_aliases
Last active August 15, 2018 12:31
bash aliases
alias cd..='cd ..'
alias ..="cd .."
alias ...="cd ../.."
alias ....="cd ../../.."
alias .....="cd ../../../.."
alias c='clear'
alias h='history'
alias l='ls -lrth'
@Aracki
Aracki / .gitconfig
Last active August 12, 2016 11:36
git config
[user]
name = Ivan Aracki
email = aracki.ivan@gmail.com
[core]
editor = vim
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol
excludesfile = ~/.gitignore
[sendemail]
smtpencryption = tls
smtpserver = smtp.gmail.com
@Aracki
Aracki / ubuntu_16.04_install
Created June 8, 2016 08:41
Java, VirtualBox, Vagrant, Slack, Skype . . .
#!/bin/bash
# upgrade system
sudo apt-get update
sudo apt-get -y upgrade
# disable guest
sudo mkdir /etc/lightdm/lightdm.conf.d
@Aracki
Aracki / fileTreeStructure.js
Created July 12, 2016 16:30
algorithm for creating file tree structure from flat file paths (for kendo table)
// algorithm for creating file tree structure from flat file paths (for kendo table)
function createFileTreeStructure(filePaths){
var prefix;
var items = {
"root" : []
};
if(typeof filePaths === 'undefined' && filePaths.length == 0) {
return null;
@Aracki
Aracki / deploymentScript.sh
Last active April 13, 2017 11:52
script for deploying
#! /bin/bash
git pull origin master \
&& ./gradlew build \
&& kill -9 `ps -ef | grep java | grep -v grep | awk '{print $2}'`
function isServiceLive {
running=0;
while [ $running -eq 0 ]; do
if [ "$response" != "Web service is working!" ]; then
sleep 1;
@Aracki
Aracki / s3fileUpload.java
Last active January 25, 2017 11:36
AWS s3 file upload in parts [java]
private File multipartToFile(MultipartFile multipartFile) {
File file = new File(multipartFile.getOriginalFilename());
try {
multipartFile.transferTo(file);
return file;
} catch (IOException e) {
e.printStackTrace();
return null;
}
}
package com.copperdm.global.web.controllers.file_controllers;
import com.amazonaws.auth.AWSCredentials;
import com.amazonaws.auth.BasicAWSCredentials;
import com.amazonaws.services.s3.AmazonS3;
import com.amazonaws.services.s3.AmazonS3Client;
import com.amazonaws.util.BinaryUtils;
import com.copperdm.global.web.config.props.AmazonProps;
import com.google.gson.JsonArray;
import com.google.gson.JsonElement;
@Aracki
Aracki / cars.md
Created November 24, 2017 09:56 — forked from madetech-com/cars.md
Language Vehicle Reason
GoLang Tesla The future, but want somebody I know to buy one first
Haskell Batmobile Looks awesome but you'll never figure out how to drive it
Java Hummer Uses way more resources than is strictly necessary
Perl Classic Mini A classic that has influenced many cars, but not practical for 2015
PHP Fiat Multipla Ugly, nobody wants to be seen driving this
Ruby Smart Car Practical design. Will get you around the city fast, but not great on motorways
Python VW Golf Solid. Reliable. Middle of the road.
@Aracki
Aracki / .ideavimrc
Created December 1, 2017 11:27
Custom .ideavimrc
nmap <S-Up> v<Up>
nmap <S-Down> v<Down>
nmap <S-Left> v<Left>
nmap <S-Right> v<Right>
vmap <S-Up> <Up>
vmap <S-Down> <Down>
vmap <S-Left> <Left>
vmap <S-Right> <Right>
imap <S-Up> <Esc>v<Up>
imap <S-Down> <Esc>v<Down>
@Aracki
Aracki / aliases
Last active March 20, 2019 17:39
my custom aliases
alias cd..='cd ..'
alias ..="cd .."
alias ...="cd ../.."
alias ....="cd ../../.."
alias .....="cd ../../../.."
alias h='history'
alias a='bat'
alias l='ls -lrthp'
alias tre='tree -L 2'