Skip to content

Instantly share code, notes, and snippets.

View yaanno's full-sized avatar

Janos Hardi yaanno

  • Budapest, Hungary
View GitHub Profile
@yaanno
yaanno / frontend.md
Created March 23, 2023 10:13
frontend
#!/bin/sh
# This hook is run after every virtualenv is activated.
# echo "Setting up the minimal layout taken from http://github.com/yaanno/budapest-py/"
# pip install http://github.com/yaanno/budapest-py/raw/master/requirements.minimal.txt
export projs=$VIRTUAL_ENV/Projects
echo "Changing directory to:" $projs
if [ ! -d $projs ]; then
#!/bin/sh
# This hook is run after a new virtualenv is activated.
echo "----------------------------------------------------------------------"
echo "Setting up the layout taken from http://github.com/yaanno/budapest-py/"
echo "Please chose a layout (minimal|django|djangodzilla|none):"
read layout
if [ $layout == 'minimal' ]; then
req_file='http://github.com/yaanno/budapest-py/raw/master/requirements.minimal.txt'
# in my django template
# instead of this:
article_list = [
<Article: Images and frames>,
<Article: Rich media in your prezi>,
<Article: The Prezi Workflow>
]
# lemme have this:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>example</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style type="text/css">
/* uncomment this for the last test*/
/* #example-para{display:none !important; visibility: hidden !important} */
require 'rubygems'
require 'open-uri'
require 'hpricot'
require 'mysql'
require 'sequel'
require 'timeout'
class Scraper
SITEMAP = "http://www.gstatic.com/s2/sitemaps/profiles-sitemap.xml"