Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View AlburIvan's full-sized avatar

Iván Alburquerque AlburIvan

View GitHub Profile
@AlburIvan
AlburIvan / policy.json
Created March 21, 2019 14:31
AWS S3 - Public Bucket Policy
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "AllowPublicRead",
"Effect": "Allow",
"Principal": {
"AWS": "*"
},
"Action": "s3:GetObject",
@AlburIvan
AlburIvan / build_resConfig.gradle
Created October 29, 2016 06:32
Example of build.gradle with resConfig options enabled
android {
// ...
defaultConfig {
// ...
resConfigs "en", "es"
// using vectors O(≧▽≦)O !yay
vectorDrawables.useSupportLibrary = true
}
}
@AlburIvan
AlburIvan / build_another.gradle
Created October 28, 2016 18:53
Example of ProGuard and Shrink Resources configuration
android {
// Other settings
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
@AlburIvan
AlburIvan / example_layout.xml
Last active October 29, 2016 04:37
Example layout to demostrate the changes implemented with Vector Asset Studio
<!-- before -->
<ImageView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:src="@drawable/ic_awesome_logo" />
<!-- after -->
<ImageView
android:layout_width="match_parent"
@AlburIvan
AlburIvan / build.gradle
Last active October 29, 2016 04:35
Example for medium post of a gradle configuration
android {
// ...
defaultConfig {
// ...
vectorDrawables.useSupportLibrary = true
}
}
dependencies {
// 25.0.0 as the time of this post's release
compile 'com.android.support:appcompat-v7:25.0.0'
@AlburIvan
AlburIvan / proguard-rules.pro
Created October 28, 2016 18:38
Example of an ProGuard rule file for https://medium.com/p/6e7d626e83a7
# Add project specific ProGuard rules here.
# By default, the flags in this file are appended to flags specified
# in D:\Android\sdk/tools/proguard/proguard-android.txt
# You can edit the include path and order by changing the proguardFiles
# directive in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
#
# Add any project specific keep options here: