Skip to content

Instantly share code, notes, and snippets.

View viecode09's full-sized avatar

Lutvi Rosyady viecode09

View GitHub Profile
@viecode09
viecode09 / gist:f0110ade7a1b1054faf72ff433c3e385
Created November 26, 2019 17:51 — forked from samhocevar/gist:00eec26d9e9988d080ac
Configure sshd on MSYS2 and run it as a Windows service
#!/bin/sh
#
# msys2-sshd-setup.sh — configure sshd on MSYS2 and run it as a Windows service
#
# Please report issues and/or improvements to Sam Hocevar <sam@hocevar.net>
#
# Prerequisites:
# — MSYS2 itself: http://sourceforge.net/projects/msys2/
# — admin tools: pacman -S openssh cygrunsrv mingw-w64-x86_64-editrights
#
@viecode09
viecode09 / nginx-tuning.md
Created August 30, 2018 16:08 — forked from denji/nginx-tuning.md
NGINX tuning for best performance

Moved to git repository: https://github.com/denji/nginx-tuning

NGINX Tuning For Best Performance

For this configuration you can use web server you like, i decided, because i work mostly with it to use nginx.

Generally, properly configured nginx can handle up to 400K to 500K requests per second (clustered), most what i saw is 50K to 80K (non-clustered) requests per second and 30% CPU load, course, this was 2 x Intel Xeon with HyperThreading enabled, but it can work without problem on slower machines.

You must understand that this config is used in testing environment and not in production so you will need to find a way to implement most of those features best possible for your servers.

@viecode09
viecode09 / capybara cheat sheet
Created August 15, 2018 07:42 — forked from zhengjia/capybara cheat sheet
capybara cheat sheet
=Navigating=
visit('/projects')
visit(post_comments_path(post))
=Clicking links and buttons=
click_link('id-of-link')
click_link('Link Text')
click_button('Save')
click('Link Text') # Click either a link or a button
click('Button Value')
@viecode09
viecode09 / Hadoop_install_osx.md
Created March 18, 2017 17:22
This is how to install hadoop on Mac OS

STEP 1: First Install HomeBrew, download it from http://brew.sh

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

STEP 2: Install Hadoop

$ brew search hadoop
$ brew install hadoop
@viecode09
viecode09 / DiscreteMathComputer06.txt
Created February 6, 2017 09:06 — forked from kanak/DiscreteMathComputer06.txt
Discrete Math Using a Computer: Chapter 06 Propositional Logic notes and exercise solutions
#+TITLE: DiscreteMathComputer 06 - Propositional Logic
#+DATE:
#+LATEX_HEADER: \usepackage{fullpage}
#+LATEX_HEADER: \usepackage{tgschola}
#+OPTIONS: H:3 toc:nil
* Chapter Outline
- Difficulties with informal logic
- Propositional logic (one type of formal logic)
- Three mathematical systems for reasoning about propositions:
@viecode09
viecode09 / general_interview_questions
Created February 6, 2017 08:55 — forked from skyjia/general_interview_questions
General interview questions
- What projects are you working on at home?
- What beta toys are you playing with?
- What source control do you use?
- How do you approach your documentation?
- Which tools do you use for keeping track of requirements?
- Give me an example of a project that completely failed?
- How do you design scalable applications?
- What language to you prefer for writing complex algorithms?
- Which tools are needed for testing the quality of your code?
- How to debug a web application from client, frontend, to backend?

Originally published in June 2008

When hiring Ruby on Rails programmers, knowing the right questions to ask during an interview was a real challenge for me at first. In 30 minutes or less, it's difficult to get a solid read on a candidate's skill set without looking at code they've previously written. And in the corporate/enterprise world, I often don't have access to their previous work.

To ensure we hired competent ruby developers at my last job, I created a list of 15 ruby questions -- a ruby measuring stick if you will -- to select the cream of the crop that walked through our doors.

What to expect

Candidates will typically give you a range of responses based on their experience and personality. So it's up to you to decide the correctness of their answer.