Skip to content

Instantly share code, notes, and snippets.

View Y-LyN-10's full-sized avatar
🏠
Working from home

Yulia Tenincheva Y-LyN-10

🏠
Working from home
View GitHub Profile
@Y-LyN-10
Y-LyN-10 / get-npm-package-version
Created April 16, 2021 12:25 — forked from DarrenN/get-npm-package-version
Extract version from package.json (NPM) using bash / shell
# Version key/value should be on his own line
PACKAGE_VERSION=$(cat package.json \
| grep version \
| head -1 \
| awk -F: '{ print $2 }' \
| sed 's/[",]//g')
echo $PACKAGE_VERSION
@Y-LyN-10
Y-LyN-10 / install-postgres-9.6-centos7.md
Created July 18, 2018 14:14 — forked from Ch4s3/install-postgres-9.6-centos7.md
steps for installing postgres 9.6 on Centos7 or RHEL

Update the RPM package

rpm -ivh https://yum.postgresql.org/9.6/redhat/rhel-7.3-x86_64/pgdg-centos96-9.6-3.noarch.rpm

Update packages

yum update
@Y-LyN-10
Y-LyN-10 / static_server.js
Created July 26, 2017 14:45 — forked from ryanflorence/static_server.js
Node.JS static file web server. Put it in your path to fire up servers in any directory, takes an optional port argument.
var http = require("http"),
url = require("url"),
path = require("path"),
fs = require("fs")
port = process.argv[2] || 8888;
http.createServer(function(request, response) {
var uri = url.parse(request.url).pathname
, filename = path.join(process.cwd(), uri);
@Y-LyN-10
Y-LyN-10 / .emacs
Created September 22, 2015 16:45 — forked from samertm/.emacs
Tricking Out Emacs for Go
;; from https://www.youtube.com/watch?v=r6j2W5DZRtA
;; get the following packages ("M-x package-list-packages"):
;; go-mode
;; go-eldoc
;; company-mode
;; company-go
;; get the following go programs (run each line in your shell):
;; go get golang.org/x/tools/cmd/godoc
;; go get golang.org/x/tools/cmd/goimports
;; go get github.com/rogpeppe/godef