Skip to content

Instantly share code, notes, and snippets.

@etzl
etzl / cool_window.c
Last active Mar 8, 2021
A cool looking window with extra features (using ncurses)
View cool_window.c
#include <curses.h>
#include <panel.h>
#include <menu.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
char *itemsstr[][2] = {
{"Resume", "Continue where you left"},
@etzl
etzl / panel_browse.c
Last active Oct 25, 2020
ncurses with panels a customizable window inside terminal - but not very functional :)
View panel_browse.c
#include <curses.h>
#include <panel.h>
#include <string.h>
#include <stdlib.h>
#define NLINES 10
#define NCOLS 40
#define COUNT 3
#define TEELINE 2
@etzl
etzl / IPAddress
Last active Dec 2, 2018
Get public ip and show in terminal using python with no extera package needed
View IPAddress
import requests
response = requests.get("https://httpbin.org/ip")
print(response.json()['origin'])