code
stringlengths
1
1.96M
language
stringclasses
1 value
#!/bin/sh SYSTEM=`uname -s` CATALINA_HOME=./tomcat PATH=${PATH}:./tomcat/bin export CATALINA_HOME PATH PWD=`pwd` KEYSTORE_LOCATION=$PWD/tomcat/keystore chmod +x ./$CATALINA_HOME/bin/*.sh if [ $SYSTEM = "Darwin" ]; then export JAVA_HOME=$(/usr/libexec/java_home) else if [ -z "$JAVA_HOME" ]; then ex...
Shell
#!/bin/bash cd .. cd alcor.build cd linux pushd . cd debug ccmake ../../../alcor.cmake -DCMAKE_BUILD_TYPE:STRING=Debug -G "Unix Makefiles" popd cd release cp ../debug/CMakeCache.txt ccmake ../../../alcor.cmake -DCMAKE_BUILD_TYPE:STRING=Release -G "Unix Makefiles"
Shell
#!/bin/bash cd .. cd alcor.build cd linux pushd . cd debug ccmake ../../../alcor.cmake -DCMAKE_BUILD_TYPE:STRING=Debug -G "Unix Makefiles" popd cd release cp ../debug/CMakeCache.txt ccmake ../../../alcor.cmake -DCMAKE_BUILD_TYPE:STRING=Release -G "Unix Makefiles"
Shell
# Common bash functions # Assert that the last command terminated with OK status function check_last_cmd() { status=$? if [ "$status" -ne "0" ]; then echo "$1 failed (status: $status)" echo "ABORTED" exit 1 fi echo "$1 was ok" }
Shell
#!/bin/bash # # A script to fetch the updated translations from crowdin.net. # Tested on Max osx. # # TODO: convert file formats from DOS to unix # TODO: force a crowdin package creation before downloading. source ./bash_lib.sh # NOTE(tal): waiting with 'sq' until recieving a confirmation that it works # on an actua...
Shell
#!/bin/bash # # A script to fetch the crowdin translation memory. # Tested on Max osx. source ./bash_lib.sh local_tmx_file="../archive/translations.tmx" function main() { echo "Downloading tmx file -> ${local_tmx_file}" curl -o ${local_tmx_file} http://api.crowdin.net/api/project/maniana/download-tm?key=$CIKEY ...
Shell
#!/bin/bash # # A script to patch the Android SDK library that contains ViewPager.java # Run each time upgrading to a newer version of the SDK. # # As of Aug 2012, the stock ViewPager class does not allow to control the # animation speed and results in a too fast stratup animation (the goal is # that the user will have...
Shell
#!/bin/bash INSTALL_DIR="`pwd`/jni/libraw" SRC_DIR="`pwd`/../LibRaw-0.14.7" cd $SRC_DIR export TOOLCHAIN="$HOME/NVPACK/toolchain-14" export NDK="$HOME/NVPACK/android-ndk-r8b" export SYSROOT="$TOOLCHAIN/sysroot" export PATH="$TOOLCHAIN/bin:$SYSROOT/usr/local/bin:$PATH" export ARCH="armv7-a" export SYS_ROOT="$NDK_ROOT...
Shell
#!/bin/bash INSTALL_DIR="`pwd`/jni/exiv2" SRC_DIR="`pwd`/../exiv2-0.22" cd $SRC_DIR export TOOLCHAIN="$HOME/NVPACK/toolchain-14" export NDK="$HOME/NVPACK/android-ndk-r8b" export SYSROOT="$TOOLCHAIN/sysroot" export PATH="$TOOLCHAIN/bin:$SYSROOT/usr/local/bin:$PATH" export ARCH="armv7-a" export SYS_ROOT="$NDK_ROOT/pla...
Shell
ssh -C -N -L 37010:localhost:37010 boxen.math.washington.edu
Shell
#!/bin/bash # This script creates a lvm snapshot, modify as required # # Input is always: # $1 = name of the snapshot, a random name with no spaces or non-printable chars, usually something like "duplicati-0102030011234567" # $2 = name of the device to create the snapshot for, this is the output of find-volume.sh, ...
Shell
#!/bin/bash # This script returns the device on which the volume is mounted # # Input is always: # $1 = name of the folder to locate the LVM device for # # The script MUST output a line with device="<path>", where path is the lvm id. # The script MUST output a line with mountpoint="<path>", where path is the device ...
Shell
#!/bin/bash # This script removes a lvm snapshot, modify as required # # Input is always: # $1 = name of the snapshot, a random name, same as given to create-lvm-snapshot, usually something like "duplicati-0102030011234567" # $2 = name of the device for which the snapshot was created, same as given to create-lvm-sn...
Shell
#!/bin/bash ############################################################################### # How to run scripts before or after backups ############################################################################### # Duplicati is able to run scripts before and after backups. This # functionality is available in th...
Shell
#!/bin/sh # # DMG building script adopted from: # http://el-tramo.be/git/fancy-dmg/plain/Makefile # WC_DMG=wc.dmg WC_DIR=wc TEMPLATE_DMG=template.dmg SOURCE_FILES=Duplicati.app OUTPUT=Duplicati.dmg UNWANTED_FILES="sqlite-3.6.12.so sqlite3.dll linux-sqlite-readme.txt win-tools" SHOW_USAGE_ERROR= if [ "$#" -lt "1" ]...
Shell
#!/bin/sh # # This is a stub script that allows .apps to be relocatable on OSX but still # find the managed assembly. # # This is copied from the Mono macpack tool and modified to fit Duplicati # # The Mono Version Check is from here: # http://mjhutchinson.com/journal/2010/01/24/creating_mac_app_bundle_for_gtk_app #...
Shell
#!/bin/bash export LD_LIBRARY_PATH="/usr/lib/duplicati${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" export MONO_PATH=$MONO_PATH:/usr/lib/duplicati EXE_FILE=/usr/lib/duplicati/Duplicati.CommandLine.exe APP_NAME=Duplicati.CommandLine exec -a "$APP_NAME" mono "$EXE_FILE" "$@"
Shell
#!/bin/bash export LD_LIBRARY_PATH="/usr/lib/duplicati${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" export MONO_PATH=$MONO_PATH:/usr/lib/duplicati EXE_FILE=/usr/lib/duplicati/Duplicati.exe APP_NAME=Duplicati exec -a "$APP_NAME" mono "$EXE_FILE" "$@"
Shell
#!/bin/bash # Clean the package a bit UNWANTED_FILES="sqlite3.dll win-tools sqlite-3.6.12.so StartDuplicati.sh" #Validate input SHOW_USAGE_ERROR= if [ "$#" -lt "1" ]; then SHOW_USAGE_ERROR="No input file given" fi if [ "$#" -gt "2" ]; then SHOW_USAGE_ERROR="Too many arguments" fi if [ -n "$SHOW_USAGE_ERROR" ]; ...
Shell
#!/bin/sh set -e
Shell
#!/bin/sh set -e
Shell
cd Installer/Makefile make $@
Shell
#!/bin/bash # # Copyright 2010 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
Shell
#!/bin/bash set -e # fail early VERS="$1" [ -n "$VERS" ] && VERS="${VERS}_" function die() { echo "Error: " $* echo echo "USage: $0 <version>" echo "Automatically sign [A-Z].apk" exit 1 } [ -z "$1" ] && die shopt -s extglob # extended glob pattern function process() { SRC="$1" BASE="${SRC/.apk/}" ...
Shell
#!/bin/bash # # Starts a basic web server on the port specified. # # ./serve.sh 3000 -> http://localhost:3000 # # Copyright 2012 Eric Bidelman <ebidel@gmail.com> port=$1 if [ $# -ne 1 ] then port=8000 fi open http://localhost:$port/template.html && python -m SimpleHTTPServer $port;
Shell
#!/bin/bash HEADERS="assert.h stdarg.h setjmp.h stdio.h stdlib.h string.h sys\/types.h stddef.h time.h ctype.h stdint.h" if [ "$1" = "restore" ];then for file in `find -type f | grep [.]c'$'` do if [ ! -f "$file.orig" ];then echo "Skipping $file, which is already original." continue fi echo "Restoring $file..."...
Shell
#!/bin/bash # sdlWabbitemu v0.1 ALPHA - Build script for sdlWabbitemu! # (C) Copyright 2010 Chris S. (BuckeyeDude), Albert H. (alberthro) and David Gomes (david) # # 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 So...
Shell
#!/bin/bash # sdlWabbitemu v0.1 ALPHA - Build script for sdlWabbitemu! # (C) Copyright 2010 Chris S. (BuckeyeDude) and Albert H. (alberthro) # # 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, ei...
Shell
#!/bin/bash # sdlWabbitemu v0.1 ALPHA - Build script for sdlWabbitemu! # (C) Copyright 2010 Chris S. (BuckeyeDude) and Albert H. (alberthro) # # 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, ei...
Shell
#!/bin/bash # sdlWabbitemu v0.1 ALPHA - Build script for sdlWabbitemu! # (C) Copyright 2010 Chris S. (BuckeyeDude) and Albert H. (alberthro) # # 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, ei...
Shell
#!/bin/bash HEADERS="assert.h stdarg.h setjmp.h stdio.h stdlib.h string.h sys/types.h stddef.h time.h ctype.h stdint.h" mkdir -p sys for HEADER in $HEADERS do echo "Writing $HEADER..." cat base-header > $HEADER done
Shell
#!/bin/sh # Hg Update Check # TODO: add support for checking for updates with a regular, archived source release! becho() { printf "\033[1m$@\033[0m\n" } bprintf() { printf "\033[1m$@\033[0m" } cerr() { if [ ! "$1" = "0" ];then becho "ERROR: Something went wrong. See the above output for details." exit 1 fi } ...
Shell
python setup.py install --root=$RPM_BUILD_ROOT --record=INSTALLED_FILES # 'brp-compress' gzips the man pages without distutils knowing... fix this sed -i -e 's@man/man\([[:digit:]]\)/\(.\+\.[[:digit:]]\)$@man/man\1/\2.gz@g' INSTALLED_FILES
Shell
#!/bin/sh if [ -e "`which tox`" ]; then tox $@ else echo "**** install tox globally to test all Pythons at once http://codespeak.net/tox/" python setup.py egg_info python selftest.py $@ fi
Shell
python build.py build_ext -f --inplace cd enet python setup.py build_ext -f --inplace
Shell
cd feature_server python run.py
Shell
#!/bin/bash # # Starts a basic web server on the port specified. # # ./serve.sh 3000 -> http://localhost:3000 # # Copyright 2012 Eric Bidelman <ebidel@gmail.com> port=$1 if [ $# -ne 1 ] then port=8000 fi if [ $(uname -s) == "Darwin" ] then open=open else open=xdg-open fi $open http://localhost:$port/templat...
Shell
#!/bin/sh source _locals.sh javadoc -linkoffline http://developer.android.com/reference ${ANDROID_SDK}/docs/reference \ -sourcepath ../src \ -classpath ${ANDROID_SDK}/platforms/android-17/android.jar:${ANDROID_SDK}/tools/support/annotations.jar \ -d ../../out/javadoc/ \ -notree -nonavbar...
Shell
#!/bin/sh # Detects OS we're compiling on and generates build_config.mk, # which in turn gets read while processing Makefile. # build_config.mk will set the following variables: # - PORT_CFLAGS will either set: # -DLEVELDB_PLATFORM_POSIX if cstatomic is present # -DLEVELDB_PLATFORM_NOATOMI...
Shell
#! /bin/bash # Binary of the Texturepacker: TEXTUREPACKER_BINARY=/usr/local/bin/TexturePacker # Shared Spritesheet-Output-Definitions: SPRITESHEET_OUTPUT_DIRECTORY="../assets/gfx/spritesheets/" SPRITESHEET_OUTPUT_JAVAIDS_PACKAGE="org.anddev.andengine.examples.spritesheets" SPRITESHEET_OUTPUT_JAVAIDS_DIRECTORY="../src...
Shell
# Copyright 2012 Google Inc. All Rights Reserved. # # author: psimakov@google.com (Pavel Simakov) # # This script starts local developer Google AppEngine server and initializes it # with the default data set. # # Run this script from the coursebuilder/ folder: # sh ./scripts/start.sh # usage () { echo "Options: -...
Shell
#!/bin/bash # Copyright 2014 Google Inc. All Rights Reserved. # # Wrapper script for tools/etl/etl.py that sets up the environment correctly. # # Run this script as follows: # sh ./scripts/etl.sh <arguments> # # ETL's arguments are involved; pass --help for details. You will need to # provide credentials when usin...
Shell
#! /bin/sh # Copyright 2012 Google Inc. All Rights Reserved. # # author: psimakov@google.com (Pavel Simakov) # # This script starts local developer Google AppEngine server for integration # tests and initializes it with a default data set. # # Run this script from the coursebuilder/ folder: # sh ./scripts/start_i...
Shell
#! /bin/bash # Copyright 2014 Google Inc. All Rights Reserved. # # Wrapper script to launch PyLint ( http://www.pylint.org/ ) against # CourseBuilder sources. This script is automatically run as part of # run_all_tests.py, and can be used on individual files; run with -h # option to get the "help" text on options and...
Shell
#!/bin/bash # Copyright 2012 Google Inc. All Rights Reserved. # # author: sll@google.com (Sean Lip) # Run this script from the Course Builder folder as follows: # sh ./scripts/test.sh --test_class <dotted test name> # E.g., # Run all tests in a module: # sh ./scripts/test.sh tests.unit.common_safe_dom # # ...
Shell
#!/bin/bash # Copyright 2014 Google Inc. All Rights Reserved. # # Usage: # # Run this script from the Course Builder folder. It can be run with the # following arguments: # # Deploy Course Builder to the App Engine app named in app.yaml: # sh ./scripts/deploy.sh # # Deploy Course Builder to the given App Engine ap...
Shell
# Copyright 2013 Google Inc. All Rights Reserved. # # # This script sets up all build/test dependencies including Google App Engine, # WebTest, Selenium, Chromedriver, etc. All other scripts will include this # script to setup these dependencies. # # Force shell to fail on any errors. set -e shopt -s nullglob # Se...
Shell
# Copyright 2014 Google Inc. All Rights Reserved. # # Set common config variables for developer runtime environment scripts. # NOTE: This file is also evaluated by Python scripts to get configurations # from environment variables. Do not add any non-idempotent side-effects # to this script. export SOURCE_DIR="$( cd "...
Shell
#!/bin/bash # Copyright 2014 Google Inc. All Rights Reserved. # # Wrapper script for modules.py that sets up paths correctly. Usage from your # coursebuilder/ folder: # # sh scripts/modules.sh [args] set -e . "$(dirname "$0")/common.sh" python "$COURSEBUILDER_HOME/scripts/modules.py" "$@"
Shell
#!/bin/sh # ### $Id: run.sh abhayani@redhat.com $ ### # # Mobicents Media Server Control Script # # To use this script run it as root - it will switch to the specified user # # Here is a little (and extremely primitive) startup/shutdown script # for RedHat systems. It assumes that Mobicents Media Server lives in /usr/l...
Shell
#!/bin/sh ### ====================================================================== ### ## ## ## Mobicents Media Server Bootstrap Script ## ## ...
Shell
#!/bin/sh # ### $Id: run.sh abhayani@redhat.com $ ### # # Mobicents Media Server Control Script # # To use this script run it as root - it will switch to the specified user # # Here is a little (and extremely primitive) startup/shutdown script # for RedHat systems. It assumes that Mobicents Media Server lives in /usr/l...
Shell
#!/bin/sh ### ====================================================================== ### ## ## ## Mobicents Media Server Bootstrap Script ## ## ...
Shell
#!/bin/sh ### ====================================================================== ### ## ## ## Mobicents SS7 CLI Bootstrap Script ## ## ##...
Shell
#!/bin/sh # Functions which perform the mounting / unmount for upgrades . ${PROGDIR}/backend/functions-unmount.sh mount_target_slice() { MPART="${1}" # Import any zpools zpool import -o altroot=${FSMNT} -a umount_all_dir "${FSMNT}" # Set a variable of files we want to make backups of before doing upgrad...
Shell
#!/bin/sh # Script which reads the pc-autoinstall.conf directive, and begins the install # # Source our functions scripts . ${BACKEND}/functions.sh . ${BACKEND}/functions-networking.sh . ${BACKEND}/functions-parse.sh # Check that the config file exists if [ ! -e "${1}" ] then echo "ERROR: Install configuration $1 d...
Shell
#!/bin/sh # Main install configuration parsing script # # Source our functions scripts . ${BACKEND}/functions.sh . ${BACKEND}/functions-bsdlabel.sh . ${BACKEND}/functions-cleanup.sh . ${BACKEND}/functions-disk.sh . ${BACKEND}/functions-extractimage.sh . ${BACKEND}/functions-installcomponents.sh . ${BACKEND}/functions-...
Shell
#!/bin/sh # Functions which runs commands on the system . ${BACKEND}/functions.sh . ${BACKEND}/functions-parse.sh # Function which localizes a FreeBSD install localize_freebsd() { sed -i.bak "s/lang=en_US/lang=${LOCALE}/g" ${FSMNT}/etc/login.conf rm ${FSMNT}/etc/login.conf.bak }; # Function which localizes a P...
Shell
#!/bin/sh # functions.sh # Library of functions which pc-sysinstall may call upon for parsing the config # which gets the value of a setting in the provided line get_value_from_string() { if [ ! -z "${1}" ] then VAL="`echo ${1} | cut -d '=' -f 2`" export VAL else echo "Error: Did we forgot to supply ...
Shell
#!/bin/sh # Functions which runs commands on the system . ${BACKEND}/functions.sh . ${BACKEND}/functions-parse.sh # Function which checks and sets up auto-login for a user if specified check_autologin() { get_value_from_cfg autoLoginUser if [ ! -z "${VAL}" -a "${INSTALLTYPE}" = "PCBSD" ] then AUTOU="${VAL...
Shell
#!/bin/sh # Functions which perform mounting / unmounting and switching of optical / usb media . ${BACKEND}/functions.sh . ${BACKEND}/functions-parse.sh # Displays an optical failure message opt_fail() { # If we got here, we must not have a DVD/USB we can find :( get_value_from_cfg installInteractive if [ "$...
Shell
#!/bin/sh # Functions which perform the final cleanup after an install # Finishes up with ZFS setup before unmounting zfs_cleanup_unmount() { # Loop through our FS and see if we have any ZFS partitions to cleanup for PART in `ls ${PARTDIR}` do PARTFS="`cat ${PARTDIR}/${PART} | cut -d ':' -f 1`" PARTMNT="...
Shell
#!/bin/sh # Functions which check and load any optional modules specified in the config . ${BACKEND}/functions.sh . ${BACKEND}/functions-parse.sh copy_component() { COMPONENT="$1" FAILED="0" CFILES="" # Check the type, and set the components subdir properly TYPE="`grep 'type:' ${COMPDIR}/${COMPONENT}/compo...
Shell
#!/bin/sh # Functions related to disk operations using gpart # See if device is a full disk or partition/slice is_disk() { for _dsk in `sysctl -n kern.disks` do if [ "$_dsk" = "${1}" ] ; then return 0 ; fi done return 1 } # Get a MBR partitions sysid get_partition_sysid_mbr() { INPART="0" DISK="$1" PARTN...
Shell
#!/bin/sh # Functions related mounting the newly formatted disk partitions # Mounts all the specified partition to the mount-point mount_partition() { if [ -z "${1}" -o -z "${2}" -o -z "${3}" ] then exit_err "ERROR: Missing arguments for mount_partition" fi PART="${1}" PARTFS="${2}" MNTPOINT="${3}" ...
Shell
#!/bin/sh # Functions related to disk operations using bsdlabel # Check if we are are provided a geli password on the nextline of the config check_for_enc_pass() { CURLINE="${1}" get_next_cfg_line "${CFGF}" "${CURLINE}" echo ${VAL} | grep "^encpass=" >/dev/null 2>/dev/null if [ "$?" = "0" ] ; then # Fou...
Shell
#!/bin/sh # Functions which runs commands on the system . ${BACKEND}/functions.sh . ${BACKEND}/functions-parse.sh run_chroot_cmd() { CMD="$@" echo_log "Running chroot command: ${CMD}" echo "$CMD" >${FSMNT}/.runcmd.sh chmod 755 ${FSMNT}/.runcmd.sh chroot ${FSMNT} sh /.runcmd.sh rm ${FSMNT}/.runcmd.sh }; r...
Shell
#!/bin/sh # Functions which unmount all mounted disk filesystems # Unmount all mounted partitions under specified dir umount_all_dir() { _udir="$1" _umntdirs=`mount | sort -r | grep "on $_udir" | cut -d ' ' -f 3` for _ud in $_umntdirs do umount -f ${_ud} done } # Script that adds our gmirror devices for syn...
Shell
#!/bin/sh # Functions related to disk operations using newfs # Function which performs the ZFS magic setup_zfs_filesystem() { PART="$1" PARTFS="$2" PARTMNT="$3" EXT="$4" PARTGEOM="$5" ZPOOLOPTS="$6" ROOTSLICE="`echo ${PART} | rev | cut -b 2- | rev`" ZPOOLNAME=$(get_zpool_name "${PART}") # Sleep a f...
Shell
#!/bin/sh # Functions which perform our networking setup # Function which creates a kde4 .desktop file for the PC-BSD net tray create_desktop_nettray() { NIC="${1}" echo "#!/usr/bin/env xdg-open [Desktop Entry] Exec=/usr/local/kde4/bin/pc-nettray ${NIC} Icon=network StartupNotify=false Type=Application" > ${FSMNT}...
Shell
#!/bin/sh # functions.sh # Library of functions which pc-sysinstall may call upon # Function which displays the help-index file display_help() { if [ -e "${PROGDIR}/doc/help-index" ] then cat ${PROGDIR}/doc/help-index else echo "Error: ${PROGDIR}/doc/help-index not found" exit 1 fi }; # Function w...
Shell
#!/bin/sh # Functions which perform the extraction / installation of system to disk . ${BACKEND}/functions-mountoptical.sh # Performs the extraction of data to disk from a uzip or tar archive start_extract_uzip_tar() { if [ -z "$INSFILE" ] then exit_err "ERROR: Called extraction with no install file set!" f...
Shell
#!/bin/sh FOUND="0" # Lets parse the xorg.list file, and see what varients are supported while read line do if [ "$FOUND" = "1" -a ! -z "$line" ] then echo $line | grep '! ' >/dev/null 2>/dev/null if [ "$?" = "0" ] then exit 0 else echo "$line" fi fi if [ "${FOUND}" = "0" ]...
Shell
#!/bin/sh # Script which tests "fetch" when using a network connection, and saves # if we are using direct connect, or need FTP passive mode ############################################################################# rm ${TMPDIR}/.testftp >/dev/null 2>/dev/null ping -c 2 www.pcbsd.org >/dev/null 2>/dev/null if [ "$...
Shell
#!/bin/sh # Query a disk for partitions and display them ############################# . ${PROGDIR}/backend/functions.sh . ${PROGDIR}/backend/functions-disk.sh if [ -z "${1}" ] then echo "Error: No disk specified!" exit 1 fi if [ ! -e "/dev/${1}" ] then echo "Error: Disk /dev/${1} does not exist!" exit 1 fi ...
Shell
#!/bin/sh FOUND="0" # Lets parse the xorg.list file, and see what layouts are supported while read line do if [ "$FOUND" = "1" -a ! -z "$line" ] then echo $line | grep '! ' >/dev/null 2>/dev/null if [ "$?" = "0" ] then exit 0 else echo "$line" fi fi if [ "${FOUND}" = "0" ] ...
Shell
#!/bin/sh dmesgLine=`dmesg | grep "acpi_acad0"` if test "${dmesgLine}" = ""; then echo "laptop: NO" else echo "laptop: YES" fi
Shell
#!/bin/sh # Query a disk for partitions and display them ############################# . ${PROGDIR}/backend/functions.sh . ${PROGDIR}/backend/functions-disk.sh if [ -z "${1}" ] then echo "Error: No disk specified!" exit 1 fi if [ ! -e "/dev/${1}" ] then echo "Error: Disk /dev/${1} does not exist!" exit 1 fi ...
Shell
#!/bin/sh # Need access to a some unmount functions . ${PROGDIR}/backend/functions-unmount.sh echo "Running: find-update-parts" >> ${LOGOUT} rm ${TMPDIR}/AvailUpgrades >/dev/null 2>/dev/null FSMNT="/mnt" # Get the freebsd version on this partition get_fbsd_ver() { VER="`file ${FSMNT}/bin/sh | grep 'for FreeBSD'...
Shell
#!/bin/sh # Script which enables networking with specified options ########################################################################### . ${PROGDIR}/backend/functions.sh . ${PROGDIR}/conf/pc-sysinstall.conf . ${BACKEND}/functions-networking.sh . ${BACKEND}/functions-parse.sh NIC="$1" IP="$2" NETMASK="$3" DNS=...
Shell
#!/bin/sh # Script which lists the backups present on a server ########################################################################### . ${PROGDIR}/backend/functions.sh SSHUSER=$1 SSHHOST=$2 SSHPORT=$3 if [ -z "${SSHHOST}" -o -z "${SSHPORT}" ] then echo "ERROR: Usage list-rsync-backups.sh <user> <host> <port>"...
Shell
#!/bin/sh MEM=`sysctl hw.realmem | sed "s|hw.realmem: ||g"` MEM=`expr $MEM / 1024` MEM=`expr $MEM / 1024` echo $MEM
Shell
#!/bin/sh # Script which creates a gzipped log and optionally mails it to the specified address ############################################################################ . ${PROGDIR}/backend/functions.sh . ${PROGDIR}/conf/pc-sysinstall.conf . ${BACKEND}/functions-networking.sh . ${BACKEND}/functions-parse.sh # Bri...
Shell
#!/bin/sh # Script which checks if we are running from install media, or real system ############################################################################# dmesg | grep "md0: Preloaded image" >/dev/null 2>/dev/null if [ "$?" = "0" ] then echo "INSTALL-MEDIA" exit 0 else echo "REAL-DISK" exit 1 fi
Shell
#!/bin/sh FOUND="0" # Lets parse the xorg.list file, and see what models are supported while read line do if [ "$FOUND" = "1" -a ! -z "$line" ] then echo $line | grep '! ' >/dev/null 2>/dev/null if [ "$?" = "0" ] then exit 0 else model="`echo $line | sed 's|(|[|g'`" model="`echo...
Shell
#!/bin/sh rm ${TMPDIR}/.tzonetmp >/dev/null 2>/dev/null # Backend script which lists all the available timezones for front-ends to display while read line do echo "$line" | grep "^#" >/dev/null 2>/dev/null if [ "$?" != "0" ] then echo "$line" | tr -s "\t" ":" | cut -d ":" -f 3-4 >>${TMPDIR}/.tzonetmp fi ...
Shell
#!/bin/sh rm /tmp/netCards 2>/dev/null touch /tmp/netCards config="`ifconfig -l`" for i in $config do echo "${i}" | grep -e "lo0" -e "^fwe" -e "^fwip" -e "lo1" -e "^plip" -e "^pfsync" -e "^pflog" -e "^tun" >/dev/null 2>/dev/null if [ "$?" != "0" ] then IDENT="<`dmesg | grep ^${i} | grep -v "miibus" | grep '<' ...
Shell
#!/bin/sh # Script which lists the available components for this release ########################################################################### . ${PROGDIR}/backend/functions.sh echo "Available Components:" cd ${COMPDIR} for i in `ls -d *` do if [ -e "${i}/component.cfg" -a -e "${i}/install.sh" -a -e "${i}/di...
Shell
#!/bin/sh # Create our device listing SYSDISK=$(sysctl -n kern.disks) # Now loop through these devices, and list the disk drives for i in ${SYSDISK} do # Get the current device DEV="${i}" # Make sure we don't find any cd devices case "${DEV}" in acd[0-9]*|cd[0-9]*|scd[0-9]*) continue ;; esac # Che...
Shell
#!/bin/sh FOUND="0" cat ${PROGDIR}/conf/avail-langs exit 0
Shell
#!/bin/sh pciconf -lv | grep -i vmware >/dev/null 2>/dev/null if [ "$?" = "0" ] then echo "vmware: YES" exit 0 else echo "vmware: NO" exit 1 fi
Shell
#!/bin/sh # Script which sets up password-less logins for ssh host ########################################################################### . ${PROGDIR}/backend/functions.sh SSHUSER=$1 SSHHOST=$2 SSHPORT=$3 if [ -z "${SSHUSER}" -o -z "${SSHHOST}" -o -z "${SSHPORT}" ] then echo "ERROR: Usage setup-ssh-keys <user...
Shell
#!/bin/sh ##################################################################### # Author: Kris Moore # License: BSD # Description: pc-sysinstall provides a backend for performing # system installations, as well as calls which a front-end can use # to retrive information about the system ################...
Shell
#!/bin/sh # Query a disk for partitions and display them ############################# . ${PROGDIR}/backend/functions.sh if [ -z "${1}" ] ; then echo "Error: No disk specified!" exit 1 fi if [ -z "${2}" ] ; then echo "Error: No size specified!" exit 1 fi if [ ! -e "/dev/${1}" ] ; then echo "Error: Disk /d...
Shell
#!/bin/sh # Delete a specified partition, takes effect immediately ######################################################## . ${PROGDIR}/backend/functions.sh . ${PROGDIR}/backend/functions-disk.sh if [ -z "${1}" ] then echo "Error: No partition specified!" exit 1 fi if [ ! -e "/dev/${1}" ] then echo "Error: Pa...
Shell
#!/bin/sh # Configuration options for pc-sysinstall TMPDIR="/tmp/.pc-sysinstall" export TMPDIR if [ ! -d "${TMPDIR}" ] then mkdir -p ${TMPDIR} chmod 777 ${TMPDIR} fi # Set our temp directory for storing partition information PARTDIR="${TMPDIR}/part-info" export PARTDIR # Set the SLICECFGDIR SLICECFGDIR="${TMPDI...
Shell
#!/bin/sh cd /GhostBSD/GBI gnome-terminal -e ./gbi_test.py
Shell
#!/usr/bin/sh # Copyright (c) 2011 GhostBSD # # See COPYING for licence terms. # # gbi.sh v 0.0 Tuesday, February 22 2011 10:54:53 Eric # title="EXIT: What do you want to do ?" exit_type=`zenity --width="530" --height="220" --title="$title" --list --radiolist --column="Click Here" \ --column="Exit Type" --column="...
Shell
#!/bin/bash PYTHON=${PYTHON:-python} TESTDIR=`dirname "$0"` GPROF2DOT=$TESTDIR/../gprof2dot.py FORCE= if [ "$1" == "-f" ] then FORCE=y shift fi if [ "$1" ] then FORMATS=$@ else FORMATS=" prof pstats oprofile shark callgrind hprof perf " fi for FORMAT in $FORMATS do for PROFILE in $T...
Shell
#!/bin/bash make clean # # buildable platforms of somewhat questionable support level make lilypad make pro8 make pro16 make pro20 make atmega328_pro8 make sanguino make mega make atmega88 make luminet make diecimila # # The "big three" standard bootloaders. # These need to be built AFTER the platforms, or they'll get...
Shell