Skip to content

Instantly share code, notes, and snippets.

View olegopro's full-sized avatar
🇷🇺

Oleg Desyatnikov olegopro

🇷🇺
View GitHub Profile
@alexchexes
alexchexes / chatgpt_ui_fix.user.js
Last active May 16, 2025 17:38
ChatGPT web-interface width fix (and other UI improvements)
// ==UserScript==
// @name ChatGPT CSS fixes
// @version 2025-05-16
// @updateURL https://gist.github.com/alexchexes/d2ff0b9137aa3ac9de8b0448138125ce/raw/chatgpt_ui_fix.user.js
// @downloadURL https://gist.github.com/alexchexes/d2ff0b9137aa3ac9de8b0448138125ce/raw/chatgpt_ui_fix.user.js
// @namespace http://tampermonkey.net/
// @description Adjusts width of side bar and messages of the ChatGPT web interface
// @author alexchexes
// @match https://chat.openai.com/*
// @match https://chatgpt.com/*
@jerrydeakins
jerrydeakins / remove_idea_etc
Last active July 9, 2024 14:34
Как удалить любую папку, в т.ч. и .idea, и лишние файлы из Git
Как удалить любую папку, в т.ч. и .idea, и лишние файлы из Git
Создаем файл .gitignore в корне репозитария с содержимым:
.idea
logs/
------------------------------------------------------------------
Подробнее можно ознакомиться на странице: https://git-scm.com/book/ru/v1/Основы-Git-Запись-изменений-в-репозиторий
Удаляем ненужные папки и файлы при синхронизации в Git репозиторий
@bendasvadim
bendasvadim / remove-from-git-index.txt
Last active May 6, 2025 06:32
GIT. Как полностью удалить файл из истории
1. Нужно найти все коммиты, которые изменяли файл:
git log --pretty=oneline --branches -- BIGFILE.ZIP
2.1 Удалить ссылки на файл из всей истории коммитов, начиная с последнего (пусть, хеш последнего коммита - 6df7640):
git filter-branch --index-filter 'git rm --cached BIGFILE.ZIP --ignore-unmatch' --prune-empty --tag-name-filter cat -- --all
2.2 Удалить ссылки на каталог из истории коммитов:
git filter-branch --force --index-filter 'git rm -r --cached --ignore-unmatch BIG/DIR' --prune-empty --tag-name-filter cat -- --all
3. Отправляем изменения на сервер:
@zmts
zmts / tokens.md
Last active May 19, 2025 05:05
Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Про токены, JSON Web Tokens (JWT), аутентификацию и авторизацию. Token-Based Authentication

Last major update: 25.08.2020

  • Что такое авторизация/аутентификация
  • Где хранить токены
  • Как ставить куки ?
  • Процесс логина
  • Процесс рефреш токенов
  • Кража токенов/Механизм контроля токенов
@carlodaniele
carlodaniele / custom_menu_admin.php
Last active May 7, 2025 13:55
A basic plugin showing how to add menu metaboxes to admin menu page
<?php
/**
* @package Custom_menu_admin
* @version 1.0
*/
/*
Plugin Name: Custom menu admin
Plugin URI: http://wordpress.org/extend/plugins/#
Description: This is an example plugin
Author: Carlo Daniele