Skip to content

Instantly share code, notes, and snippets.

🐺
Hunting Knowledge

Mohammad Mirrajabi mirrajabi

🐺
Hunting Knowledge
View GitHub Profile
View migrate_repo.sh
# Assume we are in your home directory
cd ~/
# Clone the repo from GitLab using the `--mirror` option
$ git clone --mirror git@your-gitlab-site.com:mario/my-repo.git
# Change into newly created repo directory
$ cd ~/my-repo.git
# Push to GitHub using the `--mirror` option. The `--no-verify` option skips any hooks.
@mirrajabi
mirrajabi / generatepublicresources.gradle
Created Apr 19, 2017 — forked from HannahMitt/generatepublicresources.gradle
This is a gradle task to generate the public.xml file in an Android library project. It assumes all public resources are kept in a res-public/ resource source directory. Providing this as a starting point, but there may be more efficient ways.
View generatepublicresources.gradle
import groovy.xml.MarkupBuilder
// Task to generate our public.xml file
// See https://developer.android.com/studio/projects/android-library.html#PrivateResources
// We assume resources within res-public are public
task generatepublicxml {
def resDir = project.projectDir.absolutePath + "/src/main/res-public"
// Include the desired res types
@mirrajabi
mirrajabi / Album.java
Created Dec 12, 2016 — forked from krzysztof-miemiec/Album.java
List parsing done with LoganSquare and Realm database.
View Album.java
/**
* Sample class showing how to use type converter in this gist.
*
* @author Krzysztof Miemiec
*/
@JsonObject
public class Album extends RealmObject {
@PrimaryKey
@JsonField
You can’t perform that action at this time.