Skip to content

Instantly share code, notes, and snippets.

View eksahin's full-sized avatar

Engin Kadir Şahin eksahin

  • Ericsson
  • Türkiye
View GitHub Profile
@eksahin
eksahin / AdbCommands
Created September 19, 2022 08:56 — forked from Pulimet/AdbCommands
Adb useful commands list
adb help // List all comands
== Adb Server
adb kill-server
adb start-server
== Adb Reboot
adb reboot
adb reboot recovery
adb reboot-bootloader
@eksahin
eksahin / Facebook.cs
Created July 13, 2017 11:39 — forked from luca-barbieri/Facebook.cs
Facebook Login button for Xamarin Forms
// This code has been placed in the public domain.
// NO WARRANTY OF ANY KIND
// WORK IN PROGRESS AND ONLY LIMITED TESTING, MIGHT BE PARTIALLY BROKEN
// Note that you need to setup both your iOS and Android projects to include your app id and so on for this to actually work (see the Facebook docs for each platform)
// Common
public class FacebookLoginEventArgs : EventArgs
{
@eksahin
eksahin / Vagrant
Last active December 19, 2016 08:44
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure("2") do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at
@eksahin
eksahin / AppConfig.java
Created December 7, 2016 07:35 — forked from ShigeoTejima/AppConfig.java
send mail to AWS SES using spring boot
package org.test.demo;
import com.amazonaws.regions.Region;
import com.amazonaws.regions.Regions;
import com.amazonaws.services.simpleemail.AmazonSimpleEmailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
@Configuration
public class AppConfig {
@eksahin
eksahin / CreditCardEditText.java
Created July 14, 2016 20:26 — forked from alphamu/CreditCardEditText.java
A simple EditText view for use with Credit Cards. It shows an image of the credit card on the right hand side.
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.drawable.Drawable;
import android.support.v7.widget.AppCompatEditText;
import android.util.AttributeSet;
import android.util.SparseArray;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
@eksahin
eksahin / Apache Tomcat 8 Start stop script init.d script
Created June 7, 2016 07:10 — forked from miglen/Apache Tomcat 8 Start stop script init.d script
Apache Tomcat init script (or startup/controll script). Works fine for version 7/8. Read the comments for release history. Feel free to modify, copy and give suggestions. (c) GNU General Public License
#!/bin/bash
#
# description: Apache Tomcat init script
# processname: tomcat
# chkconfig: 234 20 80
#
#
# Copyright (C) 2014 Miglen Evlogiev
#
# This program is free software: you can redistribute it and/or modify it under
@eksahin
eksahin / config.fish
Created May 31, 2016 11:32 — forked from jackgris/config.fish
Example of config for fish shell
## Lenguaje Go
set --export GOROOT /usr/local/go
set -gx PATH /usr/local/go/bin $PATH
#set -gx PATH GOROOT/bin $PATH
set --export GOPATH $HOME/GoProjects
set -gx PATH $GOPATH/bin $PATH
## AppEngine para GO
set -gx PATH $HOME/programs/go_appengine $PATH
@eksahin
eksahin / dupe-finder.js
Created December 22, 2015 13:57 — forked from chrisckchang/dupe-finder.js
Aggregation query to find duplicate key values
// Desired unique index:
// db.collection.ensureIndex({ firstField: 1, secondField: 1 }, { unique: true})
db.collection.aggregate([
{ $group: {
_id: { firstField: "$firstField", secondField: "$secondField" },
uniqueIds: { $addToSet: "$_id" },
count: { $sum: 1 }
}},
{ $match: {
/**
* Ödeme isteği bu method ile başlıyor.
*/
public function paymentRequest(PaymentContext $ctx)
{