This file contains 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/perl | |
use File::Glob ':glob'; | |
use strict; | |
my $dir =$ARGV[0]; | |
my @dir; | |
my @virus; | |
push @dir,$dir; | |
foreach(@dir) | |
{ | |
my @in =<$_/*>; |
This file contains 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/perl | |
use strict; | |
## use this for any help --> http://search.cpan.org/~adamk/Archive-Zip-1.28/lib/Archive/Zip.pm | |
use Archive::Zip qw( :ERROR_CODES :CONSTANTS ); # we are using the Archive::Zip module, if its not there download it using ppm | |
my $zipfile = "abc.zip"; # name of the zip file | |
my @files = qw( a b c ); # list of files to be zipped | |
my $zip = Archive::Zip->new(); # just creating the object | |
foreach (@files) | |
{ | |
$zip->addFile($_); # adding individual files from @files |
This file contains 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/perl | |
use strict; | |
use File::Glob ':glob'; # for whitespace problem with normal glob | |
use File::Copy; # for copying files | |
use strict; | |
my @dir; # will hold all original dirs | |
my @files; # will hold all original files | |
my @ndir; # will hold all new dirs | |
my @nfiles; # will hold all new files |
This file contains 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
#sms archiver for pys60 - Project 21 | |
# sms.py | |
import inbox | |
import urllib,urllib2 | |
i = inbox.Inbox() | |
m = i.sms_messages() | |
print 'hello' | |
for a in m: | |
post = {'number' : i.address(a).encode('utf-8'), |
This file contains 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
; lcd test code for JHD 162a | |
; Author :- Ankur Shrivastava | |
; License : GPLv3 | |
; RS - > set it to port pin connected to RS pin of LCD | |
; R/W -> set it to port pin connected to R/W pin of LCD | |
; E -> set it to port pin connected to E pin of LCD | |
; DAT -> set it to port connected to Data pins of LCD | |
RS EQU P1.2 |
This file contains 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
/* Initial implementation for a folder lock | |
* Author: Ankur Shrivastava | |
* License: GPLv3 | |
*/ | |
import java.io.*; | |
import java.util.Enumeration; | |
import java.util.zip.*; | |
import javax.crypto.Cipher; | |
import javax.crypto.CipherOutputStream; |
This file contains 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
/* | |
* Initial implementation of a HTTP server, this is just a test which | |
* only manages GET request for file names | |
* Author: Ankur Shrivastava | |
* Licence: GPLv3+ | |
*/ | |
#include<unistd.h> | |
#include<stdio.h> | |
#include<stdlib.h> | |
#include<string.h> |
This file contains 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
\documentclass[11pt]{book} | |
\usepackage{graphicx} | |
\usepackage[empty]{fullpage} | |
\author{Ankur Shrivastava} | |
\begin{document} | |
\frontmatter | |
\begin{center} | |
\textbf{\LARGE RING}\\ | |
\vspace{40ex} | |
A mini project report submitted to\\ |
This file contains 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<X11/Xlib.h> | |
#include<X11/Xutil.h> | |
#include<X11/keysym.h> | |
#include<unistd.h> | |
#define DURATION 100 | |
int main() | |
{ | |
Display *display = NULL; |
This file contains 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
#ifndef _POLL_H | |
#define _POLL_H | |
#include "hash_table/hashtable.h" | |
#include <sys/epoll.h> | |
#define MAX_EVENTS 100 | |
#define CALLBACK(x) void (*x) (poll_event_t *, poll_event_element_t *, struct epoll_event) | |
#define ACCEPT_CB 0x01 |
OlderNewer