Skip to content

Instantly share code, notes, and snippets.

View x1unix's full-sized avatar
:shipit:
Work in progress

Denys Sedchenko x1unix

:shipit:
Work in progress
View GitHub Profile
@x1unix
x1unix / gulpfile.js
Created June 24, 2016 08:38
Babelify Gulp
gulp.task('js', function() {
browserify({
entries: './public/js/src/index.js',
insertGlobals : true,
fullPaths: true, // For discify
debug: ! isProduction
}).transform(babelify, {
presets: ['es2015'],
compact: false,
{
"version": "0.1.0",
"command": "gulp",
"isShellCommand": true,
"args": [
"--no-color"
],
"tasks": [
{
"taskName": "scripts",
@x1unix
x1unix / README.md
Created August 9, 2016 14:38 — forked from nodesocket/README.md
The perfect Gulp.js

The perfect gulp.js file

Tasks

serve

Runs a connect web server, serving files from /client on port 3000.

uglify-js

/*!
Copyright (c) 2012 Pixel Union, http://pixelunion.net
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
@x1unix
x1unix / script.js
Created September 9, 2016 11:40
indexOf as boolean
String.prototype.contains = function(char) {
return !!(~this.indexOf('1'));
};
@x1unix
x1unix / hello.c
Created September 20, 2016 12:48
Hello World C
#include <stdio.h>
#include <stdlib.h>
int main() {
char name[128];
printf("Your name: ");
scanf("%s", &name);
printf("Hello %s", name);
return 0;
}
@x1unix
x1unix / gpuset.sh
Created September 22, 2016 20:00
Start gfxCardStatus at background with force integrated GPU
#!/bin/bash
cd /Applications/gfxCardStatus.app/Contents/MacOS
./gfxCardStatus --integrated > /dev/null &
exit
@x1unix
x1unix / template-category-items-grid.php
Last active September 23, 2016 00:11
Zerif lite -grid with category items
<?php
/**
* Template Name: Страница с категориями раздела
*/
get_header();?>
<div class="clear"></div>
</header> <!-- / END HOME SECTION -->
@x1unix
x1unix / curl.md
Created November 8, 2016 20:04 — forked from btoone/curl.md
A curl tutorial using GitHub's API

Introduction

An introduction to curl using GitHub's API

The Basics

Makes a basic GET request to the specifed URI

curl https://api.github.com/users/caspyin