Skip to content

Instantly share code, notes, and snippets.

View EgoPingvina's full-sized avatar
🦖
Working from home

Aleksei Biriukov EgoPingvina

🦖
Working from home
View GitHub Profile
@2ik
2ik / cmd.bat
Last active May 1, 2024 14:40
Устранение ошибки в терминале VScode при запуске virtualenv
Ошибка:
.\venv\Scripts\activate : Невозможно загрузить файл C:\path\venv\Scripts\activate.ps1, так как выполнение сценариев отключено в этой системе.
Для получения дополнительных сведений см. about_Execution_Policies по адресу http://go.microsoft.com/fwlink/?LinkID=135170.
строка:1 знак:1
.\venv\Scripts\activate
~~~~~~~~~~~~~~~~~~~~~~~
CategoryInfo : Ошибка безопасности: (:) [], PSSecurityException
FullyQualifiedErrorId : UnauthorizedAccess
Решение проблемы:
@trafficinc
trafficinc / tree.js
Last active December 21, 2020 16:03
JS Tree data structure
var Node = function (name) {
this.children = [];
this.name = name;
}
Node.prototype = {
add: function (child) {
this.children.push(child);
},
@tomasevich
tomasevich / nginx_nodejs.md
Last active April 7, 2024 12:13
Сервер в связке Nginx + NodeJs

Сервер в связке Nginx + NodeJs

Данная пошаговая инструкция поможет освоить основы на простом примере

Для справки

Сервер поднимался на Debian 8 c характеристиками:

CPU - 1 ядро x 500 МГц

@firatkucuk
firatkucuk / delete-slack-messages.js
Last active May 1, 2024 04:17
Deletes slack public/private channel messages, private chat messages and channel thread replies.
#!/usr/bin/env node
// Channel ID is on the the browser URL.: https://mycompany.slack.com/messages/MYCHANNELID/
// Pass it as a parameter: node ./delete-slack-messages.js CHANNEL_ID
// CONFIGURATION #######################################################################################################
const token = 'SLACK TOKEN';
// Legacy tokens are no more supported.
// Please create an app or use an existing Slack App
@IzumiSy
IzumiSy / manifest.json
Last active November 6, 2022 20:29
Chrome.storage.sync example
{
"name": "SyncExtension",
"version": "0.1",
"manifest_version": 2,
"description": "Storage Sync Extension",
"permissions": [ "storage" ],
"browser_action": {
@emilsoman
emilsoman / chain-of-responsibility.js
Created February 21, 2013 11:31
Chain of Responsibility design pattern in Javascript
//Chain of responsibility design pattern
//Use strategyPipeline.handleRequest(request)
//to send the request to be handled along the
//chain-of-responsibility
var strategyPipeline = {
handleRequest: function(request){
var strategy1 = new Strategy1();
var strategy2 = new Strategy2();