Tag : Tail

Title User Language Tags Description Date
Tail a continuously growing file (like tail -f filename) Jason Morriss python

This is my version of a "File Tail" class for Python3 (will not work on Python2 w/o a couple of modifications). My original inspiration came from the perl File::Tail module.

Transparently handles files that get rotated or truncated.

  • Does not take 100% CPU.
  • Does not take up much memory.
  • Is capable of handling any size log file.
  • Not tested on Windows

Example:

from filetail import FileTail
tail = FileTail("/var/log/syslog")
for line in tail:
    print(line, end="")
May 20, 2011
Python Infinite Rotations and Tails Thomas Ahle python

This is an example of how functional ideas of infinite lists can be used in python to optimize memory usage of certain problems.

February 13, 2011
Factorial (Tail Recursion) captainhampton Lisp Tail recursive factorial November 27, 2010
"tail -f" with inode monitor Denis Barmenkov python

Sometimes tail -f launched for log file miss the point when program recreates log file. Script in this recipe monitors inode changes for specified file and restarts tail if needed.

September 21, 2010
Table data sebikovacs XHTML June 23, 2010
Recursively Reverse Print a Singly-Linked List without a Tail Pointer macosxnerd101 Java Recursively prints a singly-linked list to the console. It accepts the Head node as a param. April 12, 2010
Realistic Looking Button with CSS3 marcio CSS April 12, 2010
tgraph - Simple ASCII graphing utility Drew Gulino python

Takes a stream of numbers and outputs simple ASCII graphs of those numbers

March 1, 2010
Filter the output of a tail edeustace Bash

When tailing a log file, its sometimes handy to only show parts of it that you are interested in, this simple pipe does the job.

February 3, 2010
Ordered Double Linked List Using head and tail poncho4all C++ This snippet gives a doubly linked list with an int part that is ordered ascendant or descendant September 12, 2009
Ordered Linked List Using head and tail poncho4all C++ This snippet takes in int data and orders it in descending order and you can pull out certain value without killing the whole list September 3, 2009
Cocktail Sort in C# PsychoCoder C# Demonstration of the Cocktail Sort using C# (see http://en.wikipedia.org/wiki/Cocktail_sort) August 22, 2009
Hide Last Login xlovergirl HTML

Add this code to the "Headline" section when editing your profile.

November 25, 2008
Simple log like system Zver PHP November 18, 2008
Cocktail Sort Dark_Nexus Java A Java implementation of the cocktail sorting algorithm August 29, 2008