Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View ilabacheuski's full-sized avatar

Ilya Labacheuski ilabacheuski

View GitHub Profile
@ilabacheuski
ilabacheuski / final-projects.md
Created January 28, 2017 06:24 — forked from aorgish/final-projects.md
Темы финального проекта для тренинга Rolling Scopes

#Темы финальных проектов Основное требование к финальным проектам - это небольшое SPA (Single Page Application) веб-приложение с опрятным и чистым дизайном. Желательно использование фреймворков типа React или Angular. Должна быть либо серверная часть на nodejs, либо использованы сторонние API и веб-сервисы для получения данных, то есть или свой или сторонний бекенд, чтобы попрактиковать ajax-запросы. Если бекенд свой, то в идеале его можно разместить на бесплатном клауд-хостинге (https://www.heroku.com/, https://www.firebase.com, https://www.openshift.com и тд), если нужна база mongodb то можно воспользоваться бесплатным вариантом на https://mlab.com/.

Ниже примерные типовые приложения, которые можно взять за основу, если нет своих идей. Картинки даны для примера дизайна, делать похожим один в один необязательно. Дизайн типичных приложений можно подсмотреть в google images.

##Calendar ![Календарь](http://winsupersite.com/content/content/143

@ilabacheuski
ilabacheuski / gist:390086a4ff28e317ab78d6ed2a13e806
Created November 15, 2017 13:38 — forked from lttlrck/gist:9628955
rename git branch locally and remotely
git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
@ilabacheuski
ilabacheuski / inotifyWatchers.md
Last active November 15, 2017 13:44
Increasing the amount of inotify watchers.md
echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

If you are not interested in the technical details and only want to get Listen to work:

  • If you are running Debian, RedHat, or another similar Linux distribution, run the following in a terminal:
echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
@ilabacheuski
ilabacheuski / jest
Last active June 4, 2019 14:14
Jest commands
# Clear jest cache. Requires `jp`
rimraf $(./node_modules/jest/bin/jest.js --showConfig | jp '/configs/0/cacheDirectory')
@ilabacheuski
ilabacheuski / main.c
Created January 1, 2020 09:38
Right main.c
/* main.c - the complete listing */
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <libgen.h>
#include <errno.h>
#include <string.h>
#include <getopt.h>
/* main.c - the complete listing */
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <libgen.h>
#include <errno.h>
#include <string.h>
#include <getopt.h>
// function promiseNotCatched() {
// return Promise.resolve().then(() => {throw new Error('panic!');});
// }
// function timeoutNotCatched() {
// setTimeout(() => {
// throw new Error('panic!')
// }, 0);
// }
// Boom is a Hapi framework for creating HTTP error responses.
const Boom = require('boom');
const { ResourceNotFoundError, InternalError } = require('../lib/errors');
const findPerson = require('../lib/people/find');
// This would be a common utility function used across handlers
function mapDomainErrorToHttpResponse(error) {
if (error instanceof ResourceNotFoundError) {
return Boom.notFound(error.message, error.data.query);
}