Skip to content

Instantly share code, notes, and snippets.

View AnatolyRugalev's full-sized avatar
🌈

Toly AnatolyRugalev

🌈
View GitHub Profile
@AnatolyRugalev
AnatolyRugalev / gearman-status.sh
Created March 18, 2015 06:32
gearman-status.sh
#!/bin/bash
while :
do
clear
/usr/local/gearman/bin/gearadmin --status
echo "Press [CTRL+C] to stop.."
sleep 1
done
@AnatolyRugalev
AnatolyRugalev / npm-validate.sh
Last active August 27, 2015 07:17
npm install command by default is slow even if all packages are already installed. This script was used on CI server to install actual packages
#/usr/bin/env bash
PACKAGES_TO_INSTALL=$( npm list --depth=0 2>&1 > /dev/null | grep "ERR! missing" -c )
PACKAGES_TO_PRUNE=$( npm list --depth=0 2>&1 > /dev/null | grep "ERR! extraneous" -c )
if [ ${PACKAGES_TO_PRUNE} != "0" ]
then
echo "Prune ${PACKAGES_TO_PRUNE} NPM package(s)..."
npm prune
fi
<?php
namespace common\queue;
use PhpAmqpLib\Channel\AMQPChannel;
use PhpAmqpLib\Connection\AMQPStreamConnection;
use PhpAmqpLib\Message\AMQPMessage;
use Yii;
use yii\base\Component;
use yii\base\Exception;
var gulp = require('gulp');
var gutil = require('gulp-util');
var gaglio = require('gulp-aglio');
var aglio = require('aglio');
var fs = require('fs');
var request = require('request');
var apiaryApiKey = 'api-key';
var apiaryApiName = 'api-name';
@AnatolyRugalev
AnatolyRugalev / dotask.sh
Created August 18, 2019 12:44 — forked from fmartingr/dotask.sh
Taskwarrior helper for rofi
#!/bin/bash
TMPFILE='/tmp/rofi-dmenu-taskwarrior'
task rofi rc.verbose=nothing > $TMPFILE
TASK=`rofi -dmenu -p "Task: " -i -input $TMPFILE`
TASK_ID=`echo $TASK | cut -f1 -d' '`