Skip to content

Instantly share code, notes, and snippets.

View lentiummmx's full-sized avatar

lentiummmx lentiummmx

View GitHub Profile
@Keiku
Keiku / convert_number_strings_to_numbers.py
Last active January 8, 2023 20:45
Convert number strings with commas in pandas DataFrame to float.
import pandas as pd
import locale
from locale import atof
df = pd.DataFrame([['1,200', '4,200'], ['7,000', '-0.03'], ['5', '0']],
columns=['col1', 'col2'])
# col1 col2
# 0 1,200 4,200
# 1 7,000 -0.03
# 2 5 0
@gerarldlee
gerarldlee / Ubuntu 16.04 for Development.md
Last active March 15, 2021 11:01
Development Setup on Ubuntu 16.04 Linux
@arya-oss
arya-oss / INSTALL.md
Last active February 12, 2025 15:41
Ubuntu 16.04 Developer Tools installation

Ubuntu 16.04 Developer Tools Installation

First things first !

sudo apt update
sudo apt upgrade

Standard Developer Tools

sudo apt-get install build-essential git
@JanDeDobbeleer
JanDeDobbeleer / darkconemu.xml
Last active August 10, 2023 09:41
DarkConEmu.xml
<key name="Palette4" modified="2016-08-07 14:21:13" build="160724">
<value name="Name" type="string" data="DarkConEmu"/>
<value name="ExtendColors" type="hex" data="01"/>
<value name="ExtendColorIdx" type="hex" data="0f"/>
<value name="TextColorIdx" type="hex" data="0f"/>
<value name="BackColorIdx" type="hex" data="0d"/>
<value name="PopTextColorIdx" type="hex" data="0d"/>
<value name="PopBackColorIdx" type="hex" data="0d"/>
<value name="ColorTable00" type="dword" data="001e1e1e"/>
<value name="ColorTable01" type="dword" data="00cc7a00"/>
@JamoCA
JamoCA / encodeCharacters.cfm
Last active April 30, 2020 16:31
ColdFusion encodeCharacters UDF to encode characters to/from HTML Entities or UTF-8. Optionally strips high ASCII characters (enabled by default).
<cfscript>
/* encodeCharacters 6/9/2016
Converts character to/from HTML encoded entities and utf8 characters.
@param str A string
@param str conversionto (utf8, html or xml)
@param boolean stripHighASCII (default:1) option to strip all high ASCII characters
@return A string with characters replaced with either HTML entities or UTF-8 characters
Usage: encodeCharacters("Descripción: Esta promoción es única", "html");
Usage: encodeCharacters("Descripci&oacute;n: Esta promoci&oacute;n es &uacute;nica");
Based on http://cflib.org/udf/htmlEntityToUTF8 Rewritten to allow 2way conversion
@subfuzion
subfuzion / curl.md
Last active April 30, 2025 20:39
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@renshuki
renshuki / ubuntu_agnoster_install.md
Last active December 30, 2024 16:16
Ubuntu 16.04 + Terminator + Oh My ZSH with Agnoster Theme

Install Terminator (shell)

sudo add-apt-repository ppa:gnome-terminator
sudo apt-get update
sudo apt-get install terminator

Terminator should be setup as default now. Restart your terminal (shortcut: "Ctrl+Alt+T").

Install ZSH

@raininja
raininja / conkyrc
Last active August 10, 2024 02:07
conky lua rings
conky.config = {
-- — Conky settings — #
background = true,
update_interval = 1,
cpu_avg_samples = 2,
net_avg_samples = 3,
override_utf8_locale = true,
@wesbos
wesbos / settings.json
Created July 21, 2015 13:46
Wes Bos' Sublime Text Settings
{
"added_words":
[
"Mockup",
"plugins",
"coffeescript",
"sourcemaps",
"html",
"plugin",
"init",
@mauricioaniche
mauricioaniche / Invoice.java
Created May 19, 2015 02:20
TDD For Professionals - Mocks
package module2.exercise.mocks;
import java.util.Calendar;
public class Invoice {
private Calendar date;
private String customer;
private double amount;
public Invoice(Calendar date, String customer, double amount) {