Skip to content

Instantly share code, notes, and snippets.

View Sevastyan's full-sized avatar

Sevastyan Savanyuk Sevastyan

View GitHub Profile
@Sevastyan
Sevastyan / format.sh
Created February 9, 2019 20:31
Modified `format.sh` script
#!/bin/sh
# ------------------------------------------------------
# Android Studio formatting script.
# ------------------------------------------------------
IDE_BIN_HOME="${0%/*}"
export STUDIO_PROPERTIES=$IDE_BIN_HOME/format.properties
filesToFormat=$(cat -)
@Sevastyan
Sevastyan / ItemDecoration.java
Created January 30, 2018 10:07 — forked from mandybess/ItemDecoration.java
RecyclerView extension that "sticks" items in the center on scroll
import android.graphics.Rect;
import android.support.v7.widget.RecyclerView;
import android.view.View;
public class ItemDecoration extends RecyclerView.ItemDecoration {
/**
*
* {@link #startPadding} and {@link #endPadding} are final and required on initialization
* because {@link android.support.v7.widget.RecyclerView.ItemDecoration} are drawn