Skip to content

Instantly share code, notes, and snippets.

View MBehtemam's full-sized avatar
🦄
Full Of Energey

Mohammad Bagher Ehtemam MBehtemam

🦄
Full Of Energey
View GitHub Profile
@MBehtemam
MBehtemam / gist:69964e2c095547ef3ea007e531803e0f
Created July 6, 2016 09:57
Sample .gitignore for using in Unity3D game engine
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Kk]eys
*.csproj
*.unityproj
*.sln
*.suo
@MBehtemam
MBehtemam / CameraShake.cs
Created July 10, 2016 06:40 — forked from ftvs/CameraShake.cs
Simple camera shake effect for Unity3d, written in C#. Attach to your camera GameObject.
using UnityEngine;
using System.Collections;
public class CameraShake : MonoBehaviour
{
// Transform of the camera to shake. Grabs the gameObject's transform
// if null.
public Transform camTransform;
// How long the object should shake for.
@MBehtemam
MBehtemam / Connectivity.java
Created July 31, 2016 06:15 — forked from emil2k/Connectivity.java
Android utility class for checking device's network connectivity and speed.
package com.emil.android.util;
import android.content.Context;
import android.net.ConnectivityManager;
import android.net.NetworkInfo;
import android.telephony.TelephonyManager;
/**
* Check device's network connectivity and speed
* @author emil http://stackoverflow.com/users/220710/emil
@MBehtemam
MBehtemam / my-vs-code-config.json
Last active November 7, 2017 15:43
My Visual Studio Code Config
{
"editor.fontFamily": "Operator Mono SSm Light",
"editor.fontSize": 14,
"workbench.colorTheme": "Dracula Soft",
"terminal.integrated.shell.windows": "C:\\Windows\\System32\\bash.exe",
"workbench.iconTheme": "vscode-great-icons",
"window.zoomLevel": 0,
"vim.disableAnnoyingNeovimMessage": true,
"vim.statusBarColorControl": true,
"vim.statusBarColors": {
@MBehtemam
MBehtemam / gist:bbb3f845c42d38908cc275321aec1658
Created December 25, 2017 18:53
Shorten prompt for Bash on ubuntu on windows
//first
cd ~
//then
vim .bash_profile
//and after that put this line and save and opne/close bash on ubuntu on windows
@MBehtemam
MBehtemam / vs_code_behind_proxy
Created January 3, 2018 08:43 — forked from aws-scripting-guy/vs_code_behind_proxy
Visual Studio Code - working with git behind proxy
git config --global http.proxy http://myproxyserver:8080
@MBehtemam
MBehtemam / README-Template.md
Created November 13, 2018 11:15 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@MBehtemam
MBehtemam / index.js
Last active November 21, 2018 22:36
Sample server
const express = require("express");
const bodyParser = require("body-parser");
const app = express();
app.use(bodyParser.json());
app.use(bodyParser.urlencoded({ extended: false }));
app.get("/", (req, res) => {
res.json({ hope: "loop" });
});
@MBehtemam
MBehtemam / index.spec.js
Last active November 21, 2018 21:52
first part of test , importing package
const supertest = require("supertest");
const assert = require('assert');
const app = require("../index");
@MBehtemam
MBehtemam / index.spec.js
Last active November 22, 2018 17:14
First Test
const supertest = require("supertest");
const assert = require('assert');
const app = require("../index");
describe("GET /", function() {
it("it should has status code 200", function(done) {
supertest(app)
.get("/")
.expect(200)
.end(function(err, res){