Skip to content

Instantly share code, notes, and snippets.

kjdev

Block or report user

Report or block kjdev

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@kjdev
kjdev / Dockerfile
Created Jul 25, 2016
apache-mod-brotli
View Dockerfile
FROM fedora:24
MAINTAINER kjdev <kjclev@gmail.com>
RUN dnf -y --setopt=deltarpm=false update \
&& dnf -y --setopt=deltarpm=false install mod_ssl httpd-devel gcc-c++ make automake autoconf libtool file \
&& dnf clean all \
&& rm -f /etc/httpd/conf.d/{welcome.conf,userdir.conf} \
&& rm -f /etc/httpd/conf.modules.d/{00-dav.conf,00-lua.conf,00-proxy.conf,01-cgi.conf} \
&& sed -i 's|#ServerName www.example.com:80|ServerName localhost:80|g' /etc/httpd/conf/httpd.conf \
&& sed -i 's|ErrorLog ".*"|ErrorLog /dev/stdout|g' /etc/httpd/conf/httpd.conf \
@kjdev
kjdev / git-task
Last active Dec 23, 2015
Simple git task command
View git-task
#!/usr/bin/env bash
set -e
VERSION="0.0.1"
TASKFILE=".task"
_git="/usr/bin/git"
_grep="/usr/bin/grep"
_sed="/usr/bin/sed"
View libtool_patch.sh
#!/bin/bash
files=(libtool ltmain.sh)
srcdir=`pwd`
IFS=$'\n'
for file in ${files[@]}
do
if [ ! -f ${srcdir}/${file} ]; then
continue
@kjdev
kjdev / coveralls.sh
Last active Dec 17, 2015
POST coveralls by gcov
View coveralls.sh
#!/bin/bash
usage()
{
echo "Usage: "${0##*/}" [-s FILES] [-t TOKEN] [-g DIR] [-h] [-v]"
echo ""
echo "Options:"
echo " s: source files"
echo " t: secret repo token for your repository"
echo " g: search gcov/gcda file path"
View php-ext-msgpacki.patch
--- a/msgpack.h
+++ b/msgpack.h
@@ -9,103 +9,13 @@
#include <stdint.h>
#endif
-#if HAVE_ARPA_INET_H
-#include <arpa/inet.h>
-#endif
-
@kjdev
kjdev / snapshot.el
Created Oct 4, 2012
snapshot scripts
View snapshot.el
;;; snapshot
(defun snapshot ()
(interactive)
(let ((msg (read-from-minibuffer "comment: ")))
(if (> (length msg) 0)
(shell-command (concat "~/bin/snapshot -m \"" msg "\" " (buffer-file-name)))
(shell-command (concat "~/bin/snapshot " (buffer-file-name))))))
@kjdev
kjdev / xs-client.c
Created Aug 23, 2012
ZeroMQ and Crossroads I/O
View xs-client.c
/* Crossroad I/O Client */
#include "xs/xs.h"
#include <string.h>
int main(int argc, char **argv)
{
void *ctx = xs_init();
void *backend = xs_socket(ctx, XS_DEALER);
//xs_bind (backend, "ipc://backend");
xs_bind (backend, "tcp://127.0.0.1:5570");
xs_msg_t msg;
View php-pecl-phalcon.spec
%global proj_name cphalcon
%global pecl_name phalcon
%global pecl_version 2.0.1
%{!?__pecl: %{expand: %%global __pecl %{_bindir}/pecl}}
%global php_apiver %((echo 0; php -i 2>/dev/null | sed -n 's/^PHP API => //p') | tail -1)
%{!?php_extdir: %{expand: %%global php_extdir %(php-config --extension-dir)}}
%{?filter_provides_in: %filter_provides_in %{php_extdir}/.*\.so$}
%{?filter_setup}
%global __provides_exclude_from %{?__provides_exclude_from:%__provides_exclude_from|}%{php_extdir}/.*\\.so$
@kjdev
kjdev / phalcon-2.0.1-skip-unittest-yaml.patch
Created May 22, 2015
Phalcon 2.0.1 patch: Skip UnitTest yaml
View phalcon-2.0.1-skip-unittest-yaml.patch
--- a/cphalcon/unit-tests/ConfigTest.php
+++ b/cphalcon/unit-tests/ConfigTest.php
@@ -293,12 +293,22 @@ class ConfigTest extends PHPUnit_Framework_TestCase
public function testYamlConfig()
{
+ if (!extension_loaded('yaml')) {
+ $this->markTestSkipped('Warning: yaml extension is not loaded');
+ return false;
+ }
@kjdev
kjdev / phalcon-2.0.0-view-engine-markdown.patch
Last active Aug 29, 2015
Phalcon 2.0.0 patch: Phalcon\Mvc\View\Engine\Markdown
View phalcon-2.0.0-view-engine-markdown.patch
diff --git a/config.json b/config.json
index 8183eec..b5cf118 100644
--- a/config.json
+++ b/config.json
@@ -28,6 +28,16 @@
"phalcon/mvc/model/query/parser.c",
"phalcon/mvc/view/engine/volt/parser.c",
"phalcon/mvc/view/engine/volt/scanner.c",
+ "phalcon/mvc/view/engine/markdown/parser.c",
+ "phalcon/mvc/view/engine/markdown/autolink.c",
You can’t perform that action at this time.