Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
Changes:
- Add terminalizer image
  • Loading branch information
gierens committed Nov 22, 2022
2 parents c1d876b + 3b19d8b commit cdb9ee9
Show file tree
Hide file tree
Showing 4 changed files with 374 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ ARCH=amd64

BINARY=bin/ranges
MANPAGE=docs/ranges.1.gz
GIF=docs/ranges.gif

DEB_TMP_DIR=$(NAME)_$(VERSION)_$(ARCH)
DEB_PACKAGE=$(NAME)_$(VERSION)_$(ARCH).deb
Expand Down Expand Up @@ -158,6 +159,12 @@ deb-uninstall:
perf-comparison: $(BINARY)
./scripts/perf-comparison.sh

.PHONY: gif
gif: $(GIF)

%.gif: %.yml
terminalizer render $< -o $@

.PHONY: clean
clean:
rm -f bin/*
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ and binary numbers, dates, IPv4, IPv6 and MAC addresses. The list input
is given over the standard input, so by pipe, and is assumed to be sorted,
but can have duplicates.

![ranges demo](docs/ranges.gif)

## Installation

Note that you need `make`, `gcc-11` and `pandoc` to install **ranges** from sources:
Expand Down
Binary file added docs/ranges.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
365 changes: 365 additions & 0 deletions docs/ranges.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,365 @@
# The configurations that used for the recording, feel free to edit them
config:

# Specify a command to be executed
# like `/bin/bash -l`, `ls`, or any other commands
# the default is bash for Linux
# or powershell.exe for Windows
command: bash -l

# Specify the current working directory path
# the default is the current working directory path
cwd: /home/sandro

# Export additional ENV variables
env:
recording: true

# Explicitly set the number of columns
# or use `auto` to take the current
# number of columns of your shell
cols: 80

# Explicitly set the number of rows
# or use `auto` to take the current
# number of rows of your shell
rows: 25

# Amount of times to repeat GIF
# If value is -1, play once
# If value is 0, loop indefinitely
# If value is a positive number, loop n times
repeat: 0

# Quality
# 1 - 100
quality: 100

# Delay between frames in ms
# If the value is `auto` use the actual recording delays
frameDelay: auto

# Maximum delay between frames in ms
# Ignored if the `frameDelay` isn't set to `auto`
# Set to `auto` to prevent limiting the max idle time
maxIdleTime: 2000

# The surrounding frame box
# The `type` can be null, window, floating, or solid`
# To hide the title use the value null
# Don't forget to add a backgroundColor style with a null as type
frameBox:
type: floating
title:
style:
border: 0px black solid
# boxShadow: none
# margin: 0px

# Add a watermark image to the rendered gif
# You need to specify an absolute path for
# the image on your machine or a URL, and you can also
# add your own CSS styles
watermark:
imagePath: null
style:
position: absolute
right: 15px
bottom: 15px
width: 100px
opacity: 0.9

# Cursor style can be one of
# `block`, `underline`, or `bar`
cursorStyle: block

# Font family
# You can use any font that is installed on your machine
# in CSS-like syntax
fontFamily: "Monaco, Lucida Console, Ubuntu Mono, Monospace"

# The size of the font
fontSize: 12

# The height of lines
lineHeight: 1

# The spacing between letters
letterSpacing: 0

# Theme
theme:
background: "transparent"
foreground: "#afafaf"
cursor: "#c7c7c7"
black: "#232628"
red: "#fc4384"
green: "#b3e33b"
yellow: "#ffa727"
blue: "#75dff2"
magenta: "#ae89fe"
cyan: "#708387"
white: "#d5d5d0"
brightBlack: "#626566"
brightRed: "#ff7fac"
brightGreen: "#c8ed71"
brightYellow: "#ebdf86"
brightBlue: "#75dff2"
brightMagenta: "#ae89fe"
brightCyan: "#b1c6ca"
brightWhite: "#f9f9f4"

# Records, feel free to edit them
records:
- delay: 1
content: "\e[H\e[2J\e]0;sandro@reaper: ~\a\e[;32msandro@reaper:~$\e[0m "
- delay: 1000
content: he
- delay: 83
content: a
- delay: 100
content: d
- delay: 68
content: ' '
- delay: 100
content: i
- delay: 100
content: p
- delay: 100
content: s
- delay: 169
content: "\r\n\e[?2004l\r"
- delay: 5
content: "10.0.26.253\r\n10.0.2.76\r\n10.0.11.235\r\n10.0.30.254\r\n10.0.9.233\r\n10.0.36.217\r\n10.0.37.139\r\n10.0.3.243\r\n10.0.33.209\r\n10.0.36.172\r\n\e]0;sandro@reaper:~\e\\"
- delay: 5
content: "\e]7;file://reaper/home/sandro\e\\\e[?2004h\e]0;sandro@reaper: ~\a\e[;32msandro@reaper:~$\e[0m "
- delay: 400
content: w
- delay: 92
content: c
- delay: 100
content: ' '
- delay: 100
content: '-'
- delay: 100
content: l
- delay: 100
content: ' '
- delay: 100
content: i
- delay: 67
content: p
- delay: 100
content: s
- delay: 100
content: "\r\n\e[?2004l\r"
- delay: 5
content: "10000 ips\r\n\e]0;sandro@reaper:~\e\\"
- delay: 5
content: "\e]7;file://reaper/home/sandro\e\\\e[?2004h\e]0;sandro@reaper: ~\a\e[;32msandro@reaper:~$\e[0m "
- delay: 600
content: u
- delay: 100
content: f
- delay: 100
content: f
- delay: 1000
content: "\b\e[K"
- delay: 90
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: c
- delay: 89
content: a
- delay: 100
content: t
- delay: 36
content: ' '
- delay: 100
content: i
- delay: 79
content: p
- delay: 100
content: s
- delay: 68
content: ' '
- delay: 100
content: '|'
- delay: 100
content: ' '
- delay: 100
content: s
- delay: 100
content: o
- delay: 100
content: r
- delay: 100
content: t
- delay: 90
content: ' '
- delay: 100
content: '-'
- delay: 100
content: t
- delay: 100
content: ' '
- delay: 100
content: .
- delay: 100
content: ' '
- delay: 100
content: '-'
- delay: 100
content: k
- delay: 100
content: ' '
- delay: 100
content: '3'
- delay: 100
content: ','
- delay: 100
content: '3'
- delay: 100
content: 'n'
- delay: 100
content: ' '
- delay: 100
content: '-'
- delay: 100
content: k
- delay: 100
content: ' '
- delay: 100
content: '4'
- delay: 100
content: ','
- delay: 100
content: '4'
- delay: 100
content: 'n'
- delay: 100
content: ' '
- delay: 100
content: '|'
- delay: 100
content: ' '
- delay: 100
content: h
- delay: 34
content: e
- delay: 56
content: a
- delay: 100
content: d
- delay: 200
content: "\r\n\e[?2004l\r"
- delay: 9
content: "10.0.0.0\r\n10.0.0.1\r\n10.0.0.2\r\n10.0.0.3\r\n10.0.0.4\r\n10.0.0.5\r\n10.0.0.6\r\n10.0.0.7\r\n10.0.0.8\r\n10.0.0.9\r\n\e]0;sandro@reaper:~\e\\\e]7;file://reaper/home/sandro\e\\\e[?2004h\e]0;sandro@reaper: ~\a\e[;32msandro@reaper:~$\e[0m "
- delay: 854
content: b
- delay: 79
content: e
- delay: 100
content: t
- delay: 100
content: t
- delay: 100
content: e
- delay: 57
content: r
- delay: 1317
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: "\a"
- delay: 200
content: r
- delay: 90
content: a
- delay: 100
content: 'n'
- delay: 67
content: g
- delay: 79
content: e
- delay: 100
content: s
- delay: 100
content: "\r\n\e[?2004l\rError: No input given. You must provide a file or pipe!\r\nUsage: ranges [-H|-o|-b|-d|-i|-I|-m] [-s] [-f] [-h] [FILE]\r\nTry 'ranges -h' for more information\r\n\e]0;sandro@reaper:~\e\\"
- delay: 5
content: "\e]7;file://reaper/home/sandro\e\\\e[?2004h\e]0;sandro@reaper: ~\a\e[;32msandro@reaper:~$\e[0m "
- delay: 1203
content: ranges
- delay: 200
content: "\b\b\b\b\b\bcat ips | sort -t . -k 3,3n -k 4,4n | head"
- delay: 300
content: "\b\e[K"
- delay: 90
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 90
content: "\b\e[K"
- delay: 100
content: "\b\e[K"
- delay: 100
content: ' '
- delay: 100
content: r
- delay: 100
content: a
- delay: 100
content: 'n'
- delay: 100
content: g
- delay: 56
content: e
- delay: 100
content: s
- delay: 100
content: ' '
- delay: 100
content: '-'
- delay: 100
content: i
- delay: 200
content: "\r\n"
- delay: 25
content: "\e[?2004l\r"
- delay: 12
content: "10.0.0.0 10.0.1.133\r\n10.0.1.135 10.0.12.103\r\n10.0.12.105 10.0.17.177\r\n10.0.17.179 10.0.25.214\r\n10.0.25.216 10.0.30.115\r\n10.0.30.117 10.0.32.121\r\n10.0.32.123 10.0.33.179\r\n10.0.33.181 10.0.34.202\r\n10.0.34.204 10.0.35.247\r\n10.0.35.249 10.0.38.42\r\n10.0.38.44 10.0.39.25\r\n\e]0;sandro@reaper:~\e\\\e]7;file://reaper/home/sandro\e\\\e[?2004h\e]0;sandro@reaper: ~\a\e[;32msandro@reaper:~$\e[0m "
- delay: 1000
content: f
- delay: 79
content: a
- delay: 100
content: b
- delay: 100
content: u
- delay: 100
content: l
- delay: 100
content: o
- delay: 56
content: u
- delay: 100
content: s
- delay: 100
content: ' '
- delay: 100
content: ':'
- delay: 100
content: )
- delay: 2000
content: ' '

0 comments on commit cdb9ee9

Please sign in to comment.