This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case `id -u` in | |
0) PS1="${PS1}# ";; | |
*) PS1="${PS1}$ ";; | |
esac |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PS1="`whoami`@`hostname | sed 's/\..*//'`:\w " |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div style="width: 48%; float: left; text-align: justify;"> | |
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui. Etiam rhoncus. Maecenas tempus, tellus eget condimentum rhoncus, sem quam semper libero, sit a |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/make -f | |
%: | |
dh $@ --with python2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
indicator-weather usr/bin/ | |
indicator-weather.desktop etc/xdg/autostart |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ | |
Upstream-Name: Indicator Weather | |
Source: http://blog.madadipouya.com | |
Files: * | |
Copyright: Copyright 2015 Kasra Madadipouya <[email protected]> | |
License: GPL-3 | |
Files: debian/* | |
Copyright: Copyright 2015 Kasra Madadipouya <[email protected]> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Source: indicator-weather | |
Section: python | |
Priority: optional | |
Maintainer: Kasra Madadipouya, <[email protected]> | |
Build-Depends: debhelper (>= 7), | |
python (>= 2.6.6-3~) | |
Standards-Version: 3.9.2 | |
X-Python-Version: >= 2.6 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
indicator-weather (0.4ubuntu) trusty; urgency=low | |
* Basic indicator functionalities, with some enhancements | |
* Change webservice url, move to in house web service | |
* Dynamic icon selection according to weather condition | |
* Small bug fixes | |
-- Kasra Madadipouya <[email protected]> Fri, 13 May 2016 10:01:15 +0800 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urllib, re | |
source = urllib.urlopen('http://www.cbssports.com/nba/draft/mock-draft').read() | |
f = open('out.txt', 'w') | |
for link in re.findall('http://sports.cbsimg.net/images/nba/logos/30x30/[A-Z]*.png', source): | |
print >> f, link # or f.write('...\n') | |
actually_download = True | |
if actually_download: | |
filename = link.split('/')[-1] | |
urllib.urlretrieve(link, filename) | |
f.close() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(int args, char *argv[]) | |
{ | |
char ch; | |
char key = argv[3][0]; | |
FILE *fp; | |
FILE *fp1; | |
fp = fopen(argv[1], "r"); | |
fp1 = fopen(argv[2], "w+"); | |
if (fp == NULL) |