Skip to content

Instantly share code, notes, and snippets.

Avatar

Sevastyan Savanyuk Sevastyan

View GitHub Profile
@Sevastyan
Sevastyan / format.sh
Created Feb 9, 2019
Modified `format.sh` script
View format.sh
#!/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 Jan 30, 2018 — forked from mandybess/ItemDecoration.java
RecyclerView extension that "sticks" items in the center on scroll
View ItemDecoration.java
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