diff options
author | Lars Wirzenius <liw@liw.fi> | 2012-03-11 18:49:11 +0000 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2012-03-11 18:49:11 +0000 |
commit | f77eb379fd2994c78e3bb38de68ed0c5893338be (patch) | |
tree | 1ed0fbc327d9ed7291acb0328dadd101c5c65569 | |
parent | 4d20737d6999993d2759972473d7f19a9272cf07 (diff) | |
download | extrautils-f77eb379fd2994c78e3bb38de68ed0c5893338be.tar.gz |
Remove mksparse, it's almost entirely useless
-rwxr-xr-x | mksparse | 25 | ||||
-rw-r--r-- | mksparse.1 | 31 |
2 files changed, 0 insertions, 56 deletions
diff --git a/mksparse b/mksparse deleted file mode 100755 index bc5e28f..0000000 --- a/mksparse +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/python - -import cliapp - - -class MakeSparseFile(cliapp.Application): - - def add_settings(self): - self.settings.bytesize(['size'], 'size of whole to append to file') - - def process_args(self, filenames): - if self.settings['size'] > 0: - for filename in filenames: - self.append_hole(filename, self.settings['size']) - - def append_hole(self, filename, size): - f = open(filename, 'r+b') - f.seek(size - 1, 2) - print 'pos:', f.tell() - f.write('\0') - f.close() - - -if __name__ == '__main__': - MakeSparseFile().run() diff --git a/mksparse.1 b/mksparse.1 deleted file mode 100644 index e7b54e4..0000000 --- a/mksparse.1 +++ /dev/null @@ -1,31 +0,0 @@ -.\" Copyright 2011 Lars Wirzenius <liw@liw.fi> -.\" -.\" This program is free software: you can redistribute it and/or modify -.\" it under the terms of the GNU General Public License as published by -.\" the Free Software Foundation, either version 3 of the License, or -.\" (at your option) any later version. -.\" -.\" This program is distributed in the hope that it will be useful, -.\" but WITHOUT ANY WARRANTY; without even the implied warranty of -.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -.\" GNU General Public License for more details. -.\" -.\" You should have received a copy of the GNU General Public License -.\" along with this program. If not, see <http://www.gnu.org/licenses/>. -.\" -.TH MKSPARSE 1 -.SH NAME -mksparse \- add a hole to the end of a file -.SH SYNOPSIS -.B mksparse -.RB [ \-\-size =\fISIZE\fR] -.SH DESCRIPTION -.B mksparse -appends a "whole" to the end of an existing file. -It appends one real NUL byte at the end of the whole. -.SH OPTIONS -.TP -.BR \-\-size "=\fISIZE" -Size of the whole to append. -The actual size is one byte less. - |