File: util.py

package info (click to toggle)
sqlalchemy 0.6.3-3%2Bsqueeze1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 10,744 kB
  • ctags: 15,132
  • sloc: python: 93,431; ansic: 787; makefile: 137; xml: 17
file content (8 lines) | stat: -rw-r--r-- 188 bytes parent folder | download
1
2
3
4
5
6
7
8
import re

def striptags(text):
    return re.compile(r'<[^>]*>').sub('', text)

def strip_toplevel_anchors(text):
    return re.compile(r'\.html#[-\w]+-toplevel').sub('.html', text)