diff options
author | Pascal Rigaux <pixel@mandriva.com> | 1999-09-23 00:38:28 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 1999-09-23 00:38:28 +0000 |
commit | 37860db32a298e81d107848c7021f39427ff2e29 (patch) | |
tree | aca56a7afe2ac47312f7d69037dd2be7fe5da32a /perl-install/commands.pm | |
parent | a2d6666a3797ac9d980855cc8a28cf9a6466a78c (diff) | |
download | drakx-backup-do-not-use-37860db32a298e81d107848c7021f39427ff2e29.tar drakx-backup-do-not-use-37860db32a298e81d107848c7021f39427ff2e29.tar.gz drakx-backup-do-not-use-37860db32a298e81d107848c7021f39427ff2e29.tar.bz2 drakx-backup-do-not-use-37860db32a298e81d107848c7021f39427ff2e29.tar.xz drakx-backup-do-not-use-37860db32a298e81d107848c7021f39427ff2e29.zip |
no_comment
Diffstat (limited to 'perl-install/commands.pm')
-rw-r--r-- | perl-install/commands.pm | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/perl-install/commands.pm b/perl-install/commands.pm index 3c4c19a3e..e4510a22d 100644 --- a/perl-install/commands.pm +++ b/perl-install/commands.pm @@ -393,6 +393,8 @@ sub unpack_ { } sub insmod { + my ($h) = getopts(\@_, qw(h)); + $h || @_ == 0 and die "usage: insmod <module> [options]\n"; my $name = shift; my $f = "/tmp/$name.o"; require 'run_program.pm'; @@ -402,6 +404,15 @@ sub insmod { unlink $f; } +sub modprobe { + my ($h) = getopts(\@_, qw(h)); + $h || @_ == 0 and die "usage: modprobe <module> [options]\n"; + my $name = shift; + require 'modules.pm'; + modules::load_deps("/modules/modules.dep"); + modules::load($name, '', @_); +} + sub route { @_ == 0 or die "usage: route\nsorry, no modification handled\n"; my ($titles, @l) = cat_("/proc/net/route"); @@ -459,6 +470,18 @@ $dev, $size, $used, $free, $use, $mntpoint } } +sub kill { + my $signal = 15; + @_ or die "usage: kill [-<signal>] pids\n"; + $signal = (shift, $1)[1] if $_[0] =~ /^-(.*)/; + kill $signal, @_ or die "kill failed: $!\n"; +} + +sub lspci { + require 'pci_probing/main.pm'; + print join "\n", pci_probing::main::list (), ''; +} + #-###################################################################################### #- Wonderful perl :( #-###################################################################################### |