Skip to content

Instantly share code, notes, and snippets.

View ShadowKyogre's full-sized avatar

ShadowKyogre

View GitHub Profile
@joninvski
joninvski / Android_dev_in_vim.md
Last active June 2, 2016 14:22
Android development in vim

First put a the following init.d gradle script in ${HOME}/.gradle/init.d/ (currently in build.gradle but not working in init):

 allprojects {
      tasks.withType(Compile) { // Use JavaCompile for gradle > 2.0
          options.compilerArgs << "-Xlint:deprecation"
      }
      task printDependencies << {task -> println "Subproject -> $task.project.name" }
 }

subprojects {

@ixiyang
ixiyang / WebviewFragment
Last active August 29, 2015 14:04
webview file upload,handle 4.4.x
public class WebFragment extends Fragment implements OnRefreshListener<WebView> {
public static final String TAG = "WebFragment";
public static final String URL = "url";
public static final String IS_SINGLE_COLUMN = "is_single_column";
private String url;
PullToRefreshWebView refreshWebView;
private WebView webView;
private ProgressBar progressBar;
private boolean isSingleColumn;
private ValueCallback<Uri> mUploadMessage;
@denilsonsa
denilsonsa / 51-these-are-not-joysticks.rules
Last active August 6, 2022 15:51
Fix for keyboard/mouse/tablet being detected as joystick in Linux — Moved to https://github.com/denilsonsa/udev-joystick-blacklist
#
# ███╗ ███╗ ██████╗ ██╗ ██╗███████╗██████╗ ████████╗ ██████╗
# ████╗ ████║██╔═══██╗██║ ██║██╔════╝██╔══██╗ ╚══██╔══╝██╔═══██╗
# ██╔████╔██║██║ ██║██║ ██║█████╗ ██║ ██║ ██║ ██║ ██║
# ██║╚██╔╝██║██║ ██║╚██╗ ██╔╝██╔══╝ ██║ ██║ ██║ ██║ ██║
# ██║ ╚═╝ ██║╚██████╔╝ ╚████╔╝ ███████╗██████╔╝ ██║ ╚██████╔╝
# ╚═╝ ╚═╝ ╚═════╝ ╚═══╝ ╚══════╝╚═════╝ ╚═╝ ╚═════╝
#
# ╔═════════════════════════════════════════════════════════════════╗
# ║ https://github.com/denilsonsa/udev-joystick-blacklist ║
#include "math.h"
//based on https://www.youtube.com/watch?v=GtQdIYUtAHg
//used for my alarm clock.
//warning: loud.
int main(t) {
for(;;t++){
putchar(t*t>>8);
}
}
@anqxyr
anqxyr / archived
Last active July 5, 2018 15:08
Create EPUB files with Python
The gist that used to be here has since been implemented as a complete pip-installable package: https://github.com/anqxyr/mkepub
This notice is left here as a courtesy to the people who starred/bookmarked this gist in the past.
@cheerfulstoic
cheerfulstoic / Repository Maintenance Levels.md
Last active October 31, 2024 10:28
Repository Maintenance Levels

After reading Why I'm Frequently Absent from Open Source by James Long and listening the corresponding The Changelog episode, I dwelt on the idea and believe that open source maintainers...

  • ... should never be ashamed if they don't have time for a project.
  • ... should be honest with themselves and open with their users so that everybody can be on the same page
  • ... are people and they have at one time or another responsibilities or hardships that they need to attend to which reasonably take them away from a project
  • ... may also reasonbly decide that they don't like the direction of a project or that they would like to explore other things and may leave a project permanently.

Along this line of thinking I've created a set of descriptions for different levels at which a project might be maintained. A maintainer can use these to announce to their users the current ability that they have to dedicate to a pr

@xkr47
xkr47 / README.md
Last active August 14, 2024 16:23
Script for moving/renaming files/directories arbitrarily in whole git history of single branch, using perl expressions

Install into PATH e.g. $HOME/bin/ as "git-filter-mv" and chmod a+rx git-filter-mv

It works with any special characters in filenames like tabs and linefeeds. It works with empty commits.

Based on example from git-filter-branch manpage.

If you want to print debug messages, use STDERR e.g. print STDERR "File: $_\n";

Examples: