Skip to content

Instantly share code, notes, and snippets.

View kavikumarN's full-sized avatar
:atom:

Kavikumar N kavikumarN

:atom:
View GitHub Profile
@ummahusla
ummahusla / git-overwrite-branch.sh
Last active May 20, 2024 16:27 — forked from brev/git-overwrite-branch.sh
Git overwrite branch with another branch
# overwrite master with contents of feature branch (feature > master)
git checkout feature # source name
git merge -s ours master # target name
git checkout master # target name
git merge feature # source name
@drbobbeaty
drbobbeaty / hexDump.cpp
Created November 30, 2010 21:41
Simple method to dump a ZeroMQ message to a std::string.
#include <string>
#include <strings.h>
#include <stdint.h>
std::string hexDump( zmq::message_t & aMessage ) {
// I'm going to build a hex/ascii dump like you've seen so many times before
std::string msg;
std::string ascii;
// get the pointer to the start of the message's payload - and it's size
char *buff = (char *)aMessage.data();