Skip to content

Instantly share code, notes, and snippets.

View jefo's full-sized avatar

Eugen Y jefo

View GitHub Profile
@jefo
jefo / NvChad.md
Created April 22, 2024 11:32 — forked from kashifulhaque/NvChad.md
Neovim stuff with NvChad

Neovim keybinds

  • Capital letters do the opposite of small letters in command (Press shift to trigger capital letters)
  • _ (underscore) to move the cursor at the beginning of line (doesn't switch to insert mode)
    • 0 (zero) moves the cursor to the zeroth position of the line (doesn't switch to insert mode)
  • $ (dollar) to move the cursor at the end of line (doesn't switch to insert mode)
  • d$ will delete from wherever your cursor is till the end of the line
  • f<character> to move cursor to the first occurrence of <character>
    • f( to move cursor to first occurence of (
  • t<character> to move cursor to upto but not on the first occurrence of <character>
  • t( to move cursor to first occurence of (
@jefo
jefo / sane-caching.nginx.conf
Last active February 20, 2021 11:04 — forked from philipstanislaus/sane-caching.nginx.conf
Sample Nginx config with sane caching settings for modern web development
# Sample Nginx config with sane caching settings for modern web development
#
# Motivation:
# Modern web development often happens with developer tools open, e. g. the Chrome Dev Tools.
# These tools automatically deactivate all sorts of caching for you, so you always have a fresh
# and juicy version of your assets available.
# At some point, however, you want to show your work to testers, your boss or your client.
# After you implemented and deployed their feedback, they reload the testing page – and report
# the exact same issues as before! What happened? Of course, they did not have developer tools
# open, and of course, they did not empty their caches before navigating to your site.
import * as React from 'react';
import Grid, { IGridProps } from '../Grid';
import ImgCell from '../Grid/ImgCell';
import TextCell from '../Grid/TextCell';
import LinkCell from '../Grid/LinkCell';
import { IUsersToRender } from '@src/contacts/containers/interfaces';
import UserProfilePreview from '@src/shared/UserProfilePreview';
import { ProjectRow, IProjectRowProps } from '../ProjectsGrid';
const mail = require('./assets/images/mail.svg');
import * as React from 'react';
import cn from 'classnames';
import { TransitionGroup } from 'react-transition-group';
import { Preloader } from '@shared/Preloader';
import { Scrollable } from '@shared/Scrollable';
import { NextPageButton } from '@shared/NextPageButton';
import { FilterForm } from '../FilterForm';
import { IInputProps } from '@src/shared/inputs/Input/Input';
import Scrollbars from 'react-custom-scrollbars';
import Row from './Row';
@jefo
jefo / tour.component.ts
Last active February 15, 2017 15:00
tour.component.ts
import {
Component,
ChangeDetectionStrategy,
ChangeDetectorRef,
OnInit,
ViewChild,
NgZone
} from '@angular/core';
import { COMMON_PIPES, COMMON_DIRECTIVES } from '@angular/common';
import { RouteParams, Router, CanActivate } from '@angular/router-deprecated';
@jefo
jefo / client-main-screen.component.ts
Created February 15, 2017 14:50
client-main-screen.component.ts
import {
Component,
OnInit,
ChangeDetectionStrategy,
ViewChild,
DoCheck,
Inject,
ChangeDetectorRef,
NgZone
} from '@angular/core';
@jefo
jefo / generateUuid.sql
Last active April 20, 2021 15:32
Derby DB generate uuid
create type uuid external name 'java.util.UUID' language java;
create function generateUuid() returns uuid
language java
parameter style java
external name 'java.util.UUID.randomUUID';
function whatDecimalSeparator() {
var n = 1.1;
n = n.toLocaleString().substring(1, 2);
return n;
}
@jefo
jefo / clearFileInput.js
Created December 17, 2014 11:42
Clearing input with file type
function clearFileInputField(Id) {
document.getElementById(Id).innerHTML = document.getElementById(Id).innerHTML;
}
@jefo
jefo / gist:5933738
Created July 5, 2013 10:50
dd.mm.yyyy date js parse
var parseDate = function(dateString) {
// string format is dd.mm.yyyy
var tmp = dateString.split('.');
return new Date(tmp[2], tmp[1], tmp[0]);
};