This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> /* printf, fgets */ | |
#include <stdlib.h> /* atoi */ | |
#include <string.h> | |
/** | |
* atoi_r : a wrapper for atoi. | |
* atoi from stdlib.h has undefined behaviour if input does not contain | |
* a valid integer value. this function handles that undefined behaviour | |
* for non negative integers. | |
* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 4a4fc1a5481afdbb1238e5edca09b17a25c7cab0 Mon Sep 17 00:00:00 2001 | |
From: =?UTF-8?q?Mehmet=20Akif=20TA=C5=9EOVA?= <[email protected]> | |
Date: Mon, 16 Jan 2017 02:06:10 +0300 | |
Subject: [PATCH] updating for stockfish 8 | |
--- | |
.SRCINFO | 6 +++--- | |
PKGBUILD | 5 +++-- | |
2 files changed, 6 insertions(+), 5 deletions(-) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Section "InputClass" | |
Identifier "touchpad" | |
MatchIsTouchpad "on" | |
MatchProduct "ETPS/2|Elantech" | |
Driver "libinput" | |
Option "Tapping" "on" | |
Option "TappingButtonMap" "lmr" | |
Option "DisableWhileTyping" "on" | |
Option "DisableWhileTyping" "on" | |
Option "NaturalScrolling" "on" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
async def command_start(bot, chat_id, args): | |
if args['chat_type'] in ('group', 'supergroup'): | |
bot.broadcast_targets.append(chat_id) | |
async def command_broadcast(bot, chat_id, args): | |
""" | |
args = {'user_id': TELEGRM_USER_ID, 'username': TELEGRAM_USER_NAME, 'params': ['hello', 'world']} | |
""" | |
user_id = args['user_id'] | |
if user_id in bot.mods: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import asyncio | |
import telepot | |
import telepot.aio | |
class MarkdownBot(telepot.aio.Bot): | |
async def handle(self, msg): | |
flavor = telepot.flavor(msg) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# File : env-gcc-i686-elf | |
# Author: Mehmet Akif TAŞOVA | |
# Usage : To setup environment use "source env-gcc-i686-elf" | |
# To deactivate environemnt, give "deactivate" command | |
# set $TARGET to your target arch | |
export _OLD_BASH_PS1="$PS1" | |
export _ORIG_PATH="$PATH" | |
function deactivate(){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
"""pip-upgrade.py: A Python script to upgrade all installed pip packages.""" | |
__author__ = "Mehmet Akif TAŞOVA" | |
__email__ = "[email protected]" | |
__license__ = "GPLv3+" | |
__version__ = "1.0.0" | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
""" | |
Mehmet Akif TAŞOVA <[email protected]> | |
A Sample class derieved from telepot.async.Bot which has an implemented command handle mechanism | |
""" | |
import telepot | |
import telepot.async | |
import asyncio |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
# | |
# Mehmet Akif TAŞOVA <[email protected]> | |
# A sample code for handling bot commands with telepot | |
# | |
import time | |
import telepot |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
# Author: Mehmet Akif TAŞOVA <[email protected]> | |
# A simple shell script to unlock mobile broadband devices | |
# on linux systems. | |
# depends on mmcli utility. | |
if [ $# -eq 1 ] ; then | |
echo "device #$1 sims are:" | |
mmcli -m $1 | grep SIM |
NewerOlder