adding some changes
This commit is contained in:
parent
11a2db0acb
commit
b740d2bfff
@ -8,7 +8,20 @@ Operation = Upgrade
|
||||
Operation = Remove
|
||||
Type = File
|
||||
Target = boot/*
|
||||
Target = usr/lib/modules/*/vmlinuz
|
||||
Target = usr/lib/initcpio/*
|
||||
|
||||
[Trigger]
|
||||
Operation = Install
|
||||
Operation = Upgrade
|
||||
Operation = Remove
|
||||
Type = Package
|
||||
Target = linux
|
||||
Target = mkinitcpio
|
||||
|
||||
[Action]
|
||||
When = PostTransaction
|
||||
Exec = /usr/local/bin/bootsync
|
||||
Depends = python-magic
|
||||
Depends = python-psutil
|
||||
Depends = python-lxml
|
||||
|
@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env python3
|
||||
|
||||
import argparse
|
||||
import hashlib
|
||||
import os
|
||||
|
||||
|
||||
_supported_hashes = hashlib.algorithms_available
|
||||
|
||||
|
||||
class Hasher(object):
|
||||
def __init__(self, hashalgo = None):
|
||||
if hashalgo not in _supported_hashes:
|
||||
raise ValueError('hashalgo not in supported hash algorithm types')
|
||||
self.hash = hashlib.new(hashalgo)
|
||||
self.hashes = {}
|
Loading…
Reference in New Issue
Block a user