Skip to content

Instantly share code, notes, and snippets.

@Constellation
Constellation / preview.desktop
Last active August 29, 2015 13:56
PDF reader script
#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Name=Preview
GenericName=Preview
Comment=Show preview of files
Exec=preview.sh %U
Terminal=false
Icon=AdobeReader9
Type=Application
{
"prologue": [
"まんがタイムきららのドキドキ☆ビジュアルコミックス"
],
"body": [
{
"theme": "原悠衣のきんいろモザイク",
"tweets": [
"アリスちゃんもふもふしたいなー",
"迷惑ですよ"
#!/bin/sh
# https://twitter.com/jspedant/status/488940416696213504
nohup xdg-open "$@" > /dev/null 2> /dev/null &
/*
Copyright (C) 2014 Yusuke Suzuki <utatane.tea@gmail.com>
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
(function(b){function a(b,d){if({}.hasOwnProperty.call(a.cache,b))return a.cache[b];var e=a.resolve(b);if(!e)throw new Error('Failed to resolve module '+b);var c={id:b,require:a,filename:b,exports:{},loaded:!1,parent:d,children:[]};d&&d.children.push(c);var f=b.slice(0,b.lastIndexOf('/')+1);return a.cache[b]=c.exports,e.call(c.exports,c,c.exports,f,b),c.loaded=!0,a.cache[b]=c.exports}a.modules={},a.cache={},a.resolve=function(b){return{}.hasOwnProperty.call(a.modules,b)?a.modules[b]:void 0},a.define=function(b,c){a.modules[b]=c};var c=function(a){return a='/',{title:'browser',version:'v0.10.26',browser:!0,env:{},argv:[],nextTick:b.setImmediate||function(a){setTimeout(a,0)},cwd:function(){return a},chdir:function(b){a=b}}}();a.define('/tools/entry-point.js',function(c,d,e,f){!function(){'use strict';b.escodegen=a('/escodegen.js',c),escodegen.browser=!0}()}),a.define('/escodegen.js',function(d,c,e,f){!function(e,f,Z,C,W,q,A,m,x,v,K,S,G,M,k,h,J,O,D,N,n,I,w,U,_){'use strict';function Q(){return{indent:null,base:n
#!/bin/sh
OS="$(uname -s)"
ARCH="$(uname -m | sed -e s/i.86/x86/ -e s/x86_64/x86/ -e s/amd64/x86/ \
-e s/sun4u/sparc64/ \
-e s/arm.*/arm/ -e s/sa110/arm/ \
-e s/s390x/s390/ -e s/parisc64/parisc/ \
-e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
-e s/sh[234].*/sh/ -e s/aarch64.*/arm64/)"
BIT="$(getconf LONG_BIT)"
case "$OS" in
#!/bin/sh
OS="$(uname -s)"
ARCH="$(uname -m | sed -e s/i.86/x86/ -e s/x86_64/x86/ -e s/amd64/x86/ \
-e s/sun4u/sparc64/ \
-e s/arm.*/arm/ -e s/sa110/arm/ \
-e s/s390x/s390/ -e s/parisc64/parisc/ \
-e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
-e s/sh[234].*/sh/ -e s/aarch64.*/arm64/)"
BIT="$(getconf LONG_BIT)"
case "$OS" in
#include <stdio.h>
#include <errno.h>
#include "xf86drm.h"
#include "xf86drmMode.h"
#include "nouveau_drm.h"
#include "nouveau.h"
int
pvdrm_device_open(const char *busid, struct nouveau_device **pdev)
#include <iostream>
int main(int argc, char** argv) {
std::string str("hello");
std::cout << "HELLO WORLD" << std::endl;
return 0;
}
/*
Copyright (C) 2014 Yusuke Suzuki <utatane.tea@gmail.com>
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the