Skip to content

Instantly share code, notes, and snippets.

View palkx's full-sized avatar
🙃

Mykhailo N. palkx

🙃
View GitHub Profile

Keybase proof

I hereby claim:

  • I am miknikif on github.
  • I am miknikif (https://keybase.io/miknikif) on keybase.
  • I have a public key whose fingerprint is C760 687A B3E8 8568 0585 92D9 694B 6A87 FF2A 4C3C

To claim this, I am signing this object:

Keybase proof

I hereby claim:

  • I am mikkra on github.
  • I am mikkra (https://keybase.io/mikkra) on keybase.
  • I have a public key whose fingerprint is 6B86 63FD 3E31 8DA8 9C29 768A 3FDA C6E4 6275 034A

To claim this, I am signing this object:

@palkx
palkx / .htaccess
Created February 21, 2021 13:02
Apache 410 redirect.
RewriteEngine On
RewriteBase /
RewriteRule ^(.*)天気/$ error410.php [L,QSA]

Lesson 11 Task

Task description

You should save, get, update and delete bookmarks using to an external API using XMLHttpRequest

API

API URL

Routes

@palkx
palkx / oss-react-ls6-practice-task.md
Last active November 28, 2020 21:20
oss-react-ls6-practice-task

Практическое задание


Задача 1

Создайте 2 компонента, один из которых должен получить prop с именем name, а затем отобразить это

Welcome {props.name} to Ossystem
@palkx
palkx / setup_yubikey_manjaro.sh
Last active December 21, 2020 14:10
This script will install all necessary stuff to activate yubikey working without sudo on fresh manjaro installation
#!/bin/bash
sudo echo "# this udev file should be used with udev 188 and newer
ACTION!=\"add|change\", GOTO=\"u2f_end\"
KERNEL==\"hidraw*\", SUBSYSTEM==\"hidraw\", ATTRS{idVendor}==\"1050\", ATTRS{idProduct}==\"0113|0114|0115|0116|0120|0402|0403|0406|0407|0410\", TAG+=\"uaccess\"
LABEL=\"u2f_end\"" > /etc/udev/rules.d/70-u2f.rules
sudo pacman -S libusb-compat pcsclite ccid
@palkx
palkx / bash_profile.md
Created October 29, 2019 07:01
My PS1 env variable

Paste it in ~/.bash_profile

# assets 𝘟 ✗ Ӽ 𝘟 𝞦 ✔ ✓ ▲ ➜
# Git status

check_status() {

red="$bold$(tput setaf 1)"
green=$(tput setaf 2)
@palkx
palkx / Global sign-off hook.md
Last active October 14, 2019 11:40
Git global sign-off hook

Add global hooks dir

git config --global core.hooksPath /path/to/my/centralized/hooks

Add commit-msg hook

#!/bin/sh

NAME=$(git config user.name)
@palkx
palkx / example-config.yml
Last active September 18, 2019 12:38
This is simple script based on telethon which can forward messages from multiple channels to your one channel, and you can create multiple rules in config.yml. Requires pyyaml and telethon install from pip3.
api_id: 111111 # This has to be an integer.
api_hash: '32symbolsstring' # Long 32 characters hash identifier.
session_name: 'session_name' # Session name.
channels:
- input_channels:
- 'channel'
- 'channel'
- 'channel'
output_channel: 'channel'
@palkx
palkx / vk_like_all_posts.js
Created November 17, 2018 23:39
Scripts likes all posts currently loaded on page. Be careful with high amount of posts, you can get silent ban from VK
var nodes=document.querySelectorAll(".like_wrap:not(.lite)"),i=0,inter=setInterval(function(){if(i==nodes.length){clearInterval(inter)};if(nodes[i].children[0].children[0].children[0].classList.length===3){nodes[i].children[0].children[0].children[0].click();console.log(`Liked post ${i} ${nodes[i]}`)};i++},2000);