Skip to content

Instantly share code, notes, and snippets.

View mdelolmo's full-sized avatar
👨‍💻

Manuel del Olmo Pomares mdelolmo

👨‍💻
View GitHub Profile
@n-belokopytov
n-belokopytov / copyDeps.gradle
Last active December 6, 2023 08:35
Gradle script that generates a task to copy all build variant's dependencies to a certain directory for use with Nexus IQ Server. It copies exploded AARs too, renaming the classes.jar file into "<aar_dependency_name>.jar".
apply plugin: 'com.android.application'
android.applicationVariants.all { variant ->
task "copyDependencies${variant.name.capitalize()}"() {
outputs.upToDateWhen { false }
doLast {
println "Executing copyDependencies${variant.name.capitalize()}"
variant.getCompileClasspath().each { fileDependency ->
def sourcePath = fileDependency.absolutePath
def destinationPath = project.projectDir.path + "/build/dependencies/${variant.name}/"
@SheldonWangRJT
SheldonWangRJT / Convert .mov or .MP4 to .gif.md
Last active May 15, 2024 22:27
Convert Movie(.mov) file to Gif(.gif) file in one command line in Mac Terminal

This notes is written by Sheldon. You can find me with #iOSBySheldon in Github, Youtube, Facebook, etc.

Need

Convert .mov/.MP4 to .gif

Reason

As a developer, I feel better to upload a short video when I create the pull request to show other viewers what I did in this PR. I tried .mov format directly got after finishing recording screen using Quicktime, however, gif offers preview in most web pages, and has smaller file size.

This is not limited to developer, anyone has this need can use this method to convert the files.

import android.view.animation.Interpolator;
/**
* Created with IntelliJ IDEA, best IDE in the world. User: castorflex Date: 06/06/13 Time: 22:18
*/
public class CustomBounceInterpolator implements Interpolator {
@Override
public float getInterpolation(float t) {
return -(float) Math.abs(Math.sin((float) Math.PI * (t + 1) * (t + 1)) * (1 - t));