This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xdg import IniFile, BaseDirectory, DesktopEntry | |
from os import path | |
import pynotify | |
# Desktop Notifications Specification: http://www.galago-project.org/specs/notification/0.9/index.html | |
title = "HANS: Device detected" | |
message = "An ebook has been plugged" | |
timeout = pynotify.EXPIRES_DEFAULT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from xdg import BaseDirectory | |
from xdg.IniFile import IniFile | |
from os import path | |
from glob import glob | |
desktop_files = [] | |
for dirname in BaseDirectory.xdg_data_dirs: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Let's say you've created a branch 'my_changes' you have pushed to Github, but now | |
# you want to remove it. | |
# Let's also set the remote which point to your Github account is 'origin' | |
# These are the needed steps: | |
# 1 - Delete the branch locally | |
git -D my_changes | |
# 2 - Push those changes (the delete) to Github |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# vendor/plugins/redmine_gist/init.rb | |
# | |
require 'redmine' | |
require 'open-uri' | |
Redmine::Plugin.register :redmine_gist do | |
name 'Redmine Gist embed plugin' | |
author 'Yasushi Abe <[email protected]>' | |
description 'This is a plugin for Redmine' |
NewerOlder