Skip to content

Instantly share code, notes, and snippets.

# Works as famous command which is exist in simple.el
# https://github.com/emacs-mirror/emacs/blob/cbc10ec71e9f189e8d6fd5c6927aec4872e0fd96/lisp/simple.el#L957
# + Feature that I implement for function is you can select text as region than it will delete spaces if it's more than 1.
# - Feature: Base function allows you leave (n)Space I don't need this, so it is not exist.
(defun just-one-space-region (begin end)
"Deletes whitespaces for selected region if they more than one"
(interactive "r")
(if (use-region-p)
(save-excursion
# Create pull request from your branch to target branch
# USAGE
# Switch for branch you want to make Pull request
# bash create_pr_from_cli.sh <target_branch> <OPTIONAL_pr_message>
# Limitation one script allows you to make PR for one repository.
# You can change this easily.
# TODO
PROJECTNAME="ProjectName"
@enisozgen
enisozgen / smart-shift-hydra.el
Created February 3, 2020 22:48
move text or region
;; https://github.com/hbin/smart-shift
;; Another text moving package which works well.
;; Easily you can shift region or current line.
;; Usage 1: Go to line call the function move it with h,j,k,l
;; Usage 2: Select the region than move them via h,j,k,l
;; Known bug If you select via V command it behaves so weird.
@enisozgen
enisozgen / turengSearch.el
Created December 1, 2015 10:01
Easy Tureng english<=>turkish search from emacs
(defun TurengSearch ()
"Tureng search"
(interactive)
(browse-url
(concat
"http://tureng.com/en/turkish-english/"
(url-hexify-string (if mark-active
(buffer-substring (region-beginning) (region-end))
(read-string "Search Tureng: "))))))
@enisozgen
enisozgen / n8n-error.js
Created August 3, 2020 07:21
Share n8n error file related with issue.
{
"name": "ReportError",
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
-480,
@enisozgen
enisozgen / stackoverflow-colors.css
Created February 25, 2020 19:05
A little snippet which changes stackoverflow UI by looking tags for more http://en.enisozgen.com/do-not-display-unnecessary-stackoverflow-tags
.tagged-ignored {
display: none;
}
.tagged-interesting {
background-color: #ff76508c;
}
;; For more check my blog http://en.enisozgen.com/ansible-surround/
;; Surroun with quotes and curly brackets
;; evil-surround-edit:
;; SPC s h converts: item --> {{ item }}
;; SPC s H converts: item --> "{{ item }}"
(add-hook 'yaml-mode-hook (lambda ()
@enisozgen
enisozgen / vimium-additional-keys.conf
Last active December 28, 2020 09:27
Additional key definitions for vimium
# About vimium https://github.com/philc/vimium
# Tab move next or previous right hand
map J nextTab
map K previousTab
# Tab move next or previous for left hand
map e nextTab
map r previousTab
@enisozgen
enisozgen / smart_navi.zsh
Created April 3, 2021 14:37
Some additional features for navi
#!/usr/bin/env zsh
# Some additional features on top of navi command
# https://github.com/denisidoro/navi
# How it works
# https://i.imgur.com/CM0Io4j.gif
# works with zsh
#!/usr/bin/env zsh
# _ _
# __ _| | _____ _ _ ___ _______| |__
# \ \/ / |/ / _ \ | | / __| |_ / __| '_ \
# > <| < __/ |_| \__ \_ / /\__ \ | | |
# /_/\_\_|\_\___|\__, |___(_)___|___/_| |_|
# |___/
last_class="none"
current_map=default