This is a not a shell script, run these commands manually. Tested working with ReadyNAS OS 6.10.4 Hotfix 1.
ls /dev/md
#!/usr/local/bin/python | |
# To get all dependencies for this, run: | |
# pip install PyYAML jinja2 | |
# To install, just copy it to /usr/local/bin. | |
import sys, os | |
import jinja2 | |
import yaml |
import re | |
# Dial-in prefixes | |
international_prefixes = { | |
'FR': "33", # France | |
'AU': "61", # Australia | |
'NZ': "64", # New Zealand | |
'UK': "44", # United Kingdon | |
'US': "1", # United States | |
'CA': "1", # Canada |
# Returns dictionary mapping lowercase model strings (e.g. 'macbookpro11,3') | |
# to a general category (e.g. "MacBook Pro (15-inch)"). | |
# Exact model names can be modified. | |
# @author Richard Hofman | |
# | |
def model_to_type_dict(): | |
type_to_model = {'Macbook Pro (Retina, 13-inch)': ['MacBookPro10,2', 'MacBookPro11,1', 'MacbookPro12,1'], | |
'MacBook Pro (13-inch)': ['MacBookPro9,2', 'MacBookPro8,1', 'MacBookPro7,1', 'MacBookPro5,5'], | |
'MacBook Pro (Retina, 15-inch)': ['MacbookPro11,4', 'MacbookPro11,5', 'MacBookPro11,2', 'MacBookPro11,3', 'MacBookPro10,1'], | |
'MacBook Pro (15-inch)': ['MacBookPro9,1', 'MacBookPro8,2', 'MacBookPro6,2', 'MacBookPro5,3', 'MacBookPro5,1', 'MacBookPro4,1', 'MacBookPro3,1', 'MacBookPro2,2', 'MacBookPro1,1'], |
# Small script which uses the "file" command to | |
# determine the types of all files in the current | |
# directory with names starting with '#'. | |
# | |
# It then sets the file extension as appropriate. | |
# Written to recover data from a badly damaged filesystem's | |
# lost&found folder, after testdisk. | |
# | |
# Author: Richard Hofman, 2015 | |
# |
# Simple Python script to fetch usage data for Vodafone NZ customers and push | |
# some summary stats to their mobile phones/tablets via Boxcar. | |
# | |
# Disclaimer: I in no way guarantee the security, continued functionality or support of this software. | |
# I am in no way affiliated with Vodafone NZ. This software is licensed under the MIT License. | |
# | |
# ----------------------- | |
# | |
# The MIT License (MIT) | |
# |