Skip to content

Instantly share code, notes, and snippets.

View NelzkieCoder's full-sized avatar

Nelzkie NelzkieCoder

View GitHub Profile
@iainconnor
iainconnor / Android Studio .gitignore
Created January 24, 2014 20:20
A .gitignore for use in Android Studio
# Built application files
/*/build/
# Crashlytics configuations
com_crashlytics_export_strings.xml
# Local configuration file (sdk path, etc)
local.properties
# Gradle generated files
@marti1125
marti1125 / gist:7405008
Created November 10, 2013 22:51
get first day and last day of month using jodatime
DateTimeFormatter formatterFecha = DateTimeFormat.forPattern("dd/MM/yyyy");
DateTime primerDiaDelMes = new DateTime().dayOfMonth().withMinimumValue();
String desde = new LocalDate(primerDiaDelMes).toString(formatterFecha);
DateTime ultimoDiaDelMes = new DateTime().dayOfMonth().withMaximumValue();
String hasta = new LocalDate(ultimoDiaDelMes).toString(formatterFecha);
@BrandonSmith
BrandonSmith / AndroidManifest.xml
Last active July 19, 2023 19:11
Quick example of how to schedule a notification in the future using AlarmManager
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.cards.notification">
<uses-sdk
android:minSdkVersion="17"
android:targetSdkVersion="17" />
<application
android:allowBackup="true"
@bverc
bverc / CountDownTimer.java
Created December 18, 2011 07:49 — forked from Gautier/CountDownTimer.java
Drop-in alternative for the Android CountDownTimer class, but which you can cancel from within onTick. Modified to include pause and resume functionality.
/*
* Copyright (C) 2008 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software