diff options
author | Slashbunny | 2014-11-24 19:53:25 -0500 |
---|---|---|
committer | Slashbunny | 2014-11-24 19:53:25 -0500 |
commit | de3dcfbe80e90c9856e4f2a1786bc3bc6f90751f (patch) | |
tree | 484f3033ec8c479e64846227efa12d0c2325a4d8 | |
parent | 0efca9af9aef8a89f248c249301466365714b686 (diff) | |
download | aur-de3dcfbe80e90c9856e4f2a1786bc3bc6f90751f.tar.gz |
Large refactoring of nwn-diamond PKGBUILD
* Modernize PKGBUILD (prepare, build, package functions)
* All DVD operations and archive extractions now happen in prepare()
* Patching only happens in prepare()
* Update nwn addons to use new github source location
* Quote all paths with variables
* Add default key file, instructions during install on how to use it
* Add key file to backup array
* Move all addon compilation to build() function
* Move all addon installation into custom _install_addons() function for
clarity
-rw-r--r-- | .SRCINFO | 37 | ||||
-rw-r--r-- | .gitignore | 13 | ||||
-rw-r--r-- | PKGBUILD | 311 | ||||
-rw-r--r-- | nwn.desktop | 2 | ||||
-rw-r--r-- | nwn.install | 33 | ||||
-rw-r--r-- | nwn.key | 9 | ||||
-rw-r--r-- | nwn.launcher | 2 |
7 files changed, 201 insertions, 206 deletions
@@ -1,12 +1,13 @@ pkgbase = nwn-diamond - pkgdesc = Neverwinter Nights is an RPG from Bioware. This requires the Diamond Collection DVD Release. + pkgdesc = Neverwinter Nights RPG from Bioware. Requires the Diamond Collection DVD. Update PKGBUILD with path to your DVD. pkgver = 1.69 - pkgrel = 7 + pkgrel = 8 url = http://nwn.bioware.com/ install = nwn.install arch = i686 arch = x86_64 - license = custom + license = custom:EULA + makedepends = git makedepends = unzip makedepends = p7zip makedepends = perl @@ -20,26 +21,30 @@ pkgbase = nwn-diamond depends = sdl_mixer provides = nwn conflicts = nwn + noextract = English_linuxclient169_xp2.tar.gz noextract = nwclientgold.tar.gz noextract = nwclienthotu.tar.gz - noextract = English_linuxclient169_xp2.tar.gz - noextract = nwmovies-latest.tar.gz + backup = opt/nwn/nwncdkey.ini source = http://nwdownloads.bioware.com/neverwinternights/linux/gold/nwclientgold.tar.gz source = http://nwdownloads.bioware.com/neverwinternights/linux/161/nwclienthotu.tar.gz source = http://files.bioware.com/neverwinternights/updates/linux/169/English_linuxclient169_xp2.tar.gz - source = http://home.roadrunner.com/~nwmovies/nwlinux-beta.tar.bz2 - source = http://home.roadrunner.com/~nwmovies/cursors.tar.gz - source = http://home.roadrunner.com/~nwmovies/nwmovies/nwmovies-latest.tar.gz + source = git+https://github.com/nwnlinux/nwlogger.git#commit=3bfa7aa5 + source = git+https://github.com/nwnlinux/nwmouse.git#commit=6df8b96f + source = git+https://github.com/nwnlinux/nwmovies.git#commit=61fb3645 + source = git+https://github.com/nwnlinux/nwuser.git#commit=3fbbf546 source = nwn.launcher source = nwn.desktop - md5sums = 0a059d55225fc32f905e86191d88a11f - md5sums = 376cdece07106ea058d42b531f3146bb - md5sums = b021f0da3b3e00848521926716fdf487 - md5sums = 3961f7464d3d5b7ac9f097aa9aa2f4d3 - md5sums = 7be935418f0ececb5660f53b7a902b38 - md5sums = 1698a83bce2050174670e30c42b9d673 - md5sums = 7fd0497f55856edf50480b5acd3136d3 - md5sums = bd7f80f5faa5ee1203371b4e8ec40638 + source = nwn.key + sha256sums = 6aea73cee2f6c9733ef4a121888cb3451d8a31b968a02e1ec897242df53395f3 + sha256sums = 0a4ace1aacd69fb166d09bd249ce5ae98dd28f580765f52e0147bb85f7dfcfd7 + sha256sums = 09715e2b95c025ef7f00d218deec1b1edce501530d8cba51d61097c69699763f + sha256sums = SKIP + sha256sums = SKIP + sha256sums = SKIP + sha256sums = SKIP + sha256sums = bcaa399db7fdaba64535cc79ee9b8e0c02851fe6c06a72c47abe98530eff63e7 + sha256sums = 50f6272eebd8de19c018a24a5b3ce4ca15bd1fff0aef818ec1036f249faa612c + sha256sums = SKIP pkgname = nwn-diamond diff --git a/.gitignore b/.gitignore index e4f398dc5b3a..b25a2927ceb5 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,8 @@ -src/ -pkg/ -*.pkg.tar.xz -*.pkg.tar -*.src.tar.gz +nwlogger/ +nwmouse/ +nwmovies/ +nwuser/ +English_linuxclient169_xp2.tar.gz +nwclientgold.tar.gz +nwclienthotu.tar.gz + @@ -1,109 +1,91 @@ -# Contributor: Slash <demodevil5[at]yahoo[dot]com> +# Maintainer: Slash <demodevil5[at]yahoo[dot]com> # Contributor: Adam Griffiths <adam_griffithsAATTdart.net.au> pkgname=nwn-diamond pkgver=1.69 -pkgrel=7 -pkgdesc="Neverwinter Nights is an RPG from Bioware. This requires the Diamond Collection DVD Release." -url="http://nwn.bioware.com/" -license=('custom') +pkgrel=8 +pkgdesc='Neverwinter Nights RPG from Bioware. Requires the Diamond Collection DVD. Update PKGBUILD with path to your DVD.' +url='http://nwn.bioware.com/' +license=('custom:EULA') arch=('i686' 'x86_64') -if [ "$CARCH" = "x86_64" ]; then +if [ "$CARCH" = 'x86_64' ]; then depends=('binkplayer' 'elfutils' 'lib32-elfutils' 'lib32-libgl' 'lib32-libstdc++5' 'lib32-libxcursor' 'lib32-libxdamage' 'lib32-mesa' 'perl' 'lib32-sdl_mixer') else depends=('binkplayer' 'elfutils' 'libgl' 'libstdc++5' 'libxcursor' 'mesa' 'perl' 'sdl_mixer') fi -makedepends=('unzip' 'p7zip' 'perl') +makedepends=('git' 'unzip' 'p7zip' 'perl') provides=('nwn') conflicts=('nwn') -install=nwn.install -source=("http://nwdownloads.bioware.com/neverwinternights/linux/gold/nwclientgold.tar.gz" \ -"http://nwdownloads.bioware.com/neverwinternights/linux/161/nwclienthotu.tar.gz" \ -"http://files.bioware.com/neverwinternights/updates/linux/169/English_linuxclient169_xp2.tar.gz" \ -"http://home.roadrunner.com/~nwmovies/nwlinux-beta.tar.bz2" \ -"http://home.roadrunner.com/~nwmovies/cursors.tar.gz" \ -"http://home.roadrunner.com/~nwmovies/nwmovies/nwmovies-latest.tar.gz" \ -"nwn.launcher" "nwn.desktop") -noextract=('nwclientgold.tar.gz' 'nwclienthotu.tar.gz' 'English_linuxclient169_xp2.tar.gz' 'nwmovies-latest.tar.gz') -md5sums=('0a059d55225fc32f905e86191d88a11f' - '376cdece07106ea058d42b531f3146bb' - 'b021f0da3b3e00848521926716fdf487' - '3961f7464d3d5b7ac9f097aa9aa2f4d3' - '7be935418f0ececb5660f53b7a902b38' - '1698a83bce2050174670e30c42b9d673' - '7fd0497f55856edf50480b5acd3136d3' - 'bd7f80f5faa5ee1203371b4e8ec40638') +install='nwn.install' +backup=('opt/nwn/nwncdkey.ini') +source=( + 'http://nwdownloads.bioware.com/neverwinternights/linux/gold/nwclientgold.tar.gz' + 'http://nwdownloads.bioware.com/neverwinternights/linux/161/nwclienthotu.tar.gz' + 'http://files.bioware.com/neverwinternights/updates/linux/169/English_linuxclient169_xp2.tar.gz' + 'git+https://github.com/nwnlinux/nwlogger.git#commit=3bfa7aa5' + 'git+https://github.com/nwnlinux/nwmouse.git#commit=6df8b96f' + 'git+https://github.com/nwnlinux/nwmovies.git#commit=61fb3645' + 'git+https://github.com/nwnlinux/nwuser.git#commit=3fbbf546' + 'nwn.launcher' + 'nwn.desktop' + 'nwn.key' +) +noextract=( + 'English_linuxclient169_xp2.tar.gz' + 'nwclientgold.tar.gz' + 'nwclienthotu.tar.gz' +) +sha256sums=('6aea73cee2f6c9733ef4a121888cb3451d8a31b968a02e1ec897242df53395f3' + '0a4ace1aacd69fb166d09bd249ce5ae98dd28f580765f52e0147bb85f7dfcfd7' + '09715e2b95c025ef7f00d218deec1b1edce501530d8cba51d61097c69699763f' + 'SKIP' + 'SKIP' + 'SKIP' + 'SKIP' + 'bcaa399db7fdaba64535cc79ee9b8e0c02851fe6c06a72c47abe98530eff63e7' + '50f6272eebd8de19c018a24a5b3ce4ca15bd1fff0aef818ec1036f249faa612c' + 'SKIP') PKGEXT='.pkg.tar' -# Directory where the NWN Diamond DVD is Mounted +# Directory where the NWN Diamond DVD is mounted +# Tip: Create an ISO from your DVD to speed up the process _dvdpath=/media/dvd -# NWN Diamond CD-Keys (Neverwinter Nights, Shadows of Undrentide, and Hordes of the Underdark) -_key_nwn=xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx -_key_sou=xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx -_key_hou=xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx-xxxxx - -build() +prepare() { - cd $srcdir/ - - # Create Destination Directory - install -d $pkgdir/opt/nwn - - # Remove nwmovies which ships with the beta code; Replace with latest - rm -rf nwmovies - tar --overwrite -zxvf $srcdir/nwmovies-latest.tar.gz -C $srcdir/ - - # Extract Data Files from DVD ROM - unzip $_dvdpath/Data_Shared.zip -d $pkgdir/opt/nwn/ || return 1 - unzip $_dvdpath/Data_linux.zip -d $pkgdir/opt/nwn/ || return 1 - unzip -o $_dvdpath/data/XP1.zip -d $pkgdir/opt/nwn/ || return 1 - unzip -o $_dvdpath/data/XP2.zip -d $pkgdir/opt/nwn/ || return 1 + # Extract Data Files from DVD + unzip -o "${_dvdpath}/Data_Shared.zip" -d "${srcdir}/gametmp/" + unzip -o "${_dvdpath}/Data_linux.zip" -d "${srcdir}/gametmp/" + unzip -o "${_dvdpath}/data/XP1.zip" -d "${srcdir}/gametmp/" + unzip -o "${_dvdpath}/data/XP2.zip" -d "${srcdir}/gametmp/" # Extract Game Clients - tar -zxvf $srcdir/nwclientgold.tar.gz -C $pkgdir/opt/nwn/ - tar -zxvf $srcdir/nwclienthotu.tar.gz -C $pkgdir/opt/nwn/ - - # Extract Kingmaker Files - 7z x $_dvdpath/KingmakerSetup.exe -xr0\!*PLUGINSDIR* -xr\!*.exe -xr\!*.dat \ - -o$srcdir/kingmakertmp/ - - # Install Kingmaker Files - cp -r $srcdir/kingmakertmp/\$0/* \ - $pkgdir/opt/nwn/ + tar -zxvf "${srcdir}/nwclientgold.tar.gz" -C "${srcdir}/gametmp/" + tar -zxvf "${srcdir}/nwclienthotu.tar.gz" -C "${srcdir}/gametmp/" # Extract Latest Patch - tar -zxvf $srcdir/English_linuxclient169_xp2.tar.gz -C $pkgdir/opt/nwn + tar -zxvf "${srcdir}/English_linuxclient169_xp2.tar.gz" -C \ + "${srcdir}/gametmp/" - # Check the Installation - cd $pkgdir/opt/nwn/ - ./fixinstall + # Extract Kingmaker Files + 7z x "${_dvdpath}/KingmakerSetup.exe" -xr0\!*PLUGINSDIR* -xr\!*.exe -xr\!*.dat \ + -o"${srcdir}/kingmakertmp/" -aoa - # Remove Unneeded Files & Directories - rm -r $pkgdir/opt/nwn/SDL-1.2.5/ + # Copy License, Icon off DVD + cp -f "${_dvdpath}/"{EULA.txt,nwn.ico} "${srcdir}" - # Install CD Key File - cat << EOF > $pkgdir/opt/nwn/nwncdkey.ini -;These are your CD Keys for Neverwinter Nights. -;DO NOT share these CD Keys with ANYONE. -;Apart from this installation, or when registering with the Official Neverwinter Nights Community Site [http://nwn.bioware.com], BioWare and Infogrames will NEVER ask you for this CD Key. - -[CDKEY] -Key3=$_key_hou -Key2=$_key_sou -Key1=$_key_nwn -EOF - - cd $srcdir/ - - ########################################################################### - # - # nwmovies: - # - # Movies in Linux Client Support for NWN - # - ########################################################################### + # Patch nwmouse so it can find user.h + /bin/sed -i 's|linux/user.h|sys/user.h|1' \ + "${srcdir}/nwmouse/nwmouse/nwmouse_cookie.c" + # Patch nwlogger so it can find user.h + /bin/sed -i 's|linux/user.h|sys/user.h|1' \ + "${srcdir}/nwlogger/nwlogger/nwlogger_cookie.c" +} + +build() +{ + cd "${srcdir}/nwmovies" # Compile nwmovies using the appropriate SDL library if [ "$CARCH" = "x86_64" ]; then ./nwmovies_install.pl /usr/lib32/libSDL-1.2.so.0 @@ -111,110 +93,115 @@ EOF ./nwmovies_install.pl /usr/lib/libSDL-1.2.so.0 fi - # Install nwmovies binaries - install -D -m 755 -t $pkgdir/opt/nwn/ \ - $srcdir/nwmovies/{nwmovies.so,nwmovies.pl} + # Compile nwuser + cd "${srcdir}/nwuser" + ./nwuser_install.pl - # Install binkplayer binaries - install -D -m 755 $srcdir/nwmovies/binklib.so \ - $pkgdir/opt/nwn/nwmovies/binklib.so + # Compile nwmouse + cd "${srcdir}/nwmouse" + ./nwmouse_install.pl - # Install libdis binaries - install -D -m 755 $srcdir/nwmovies/libdis/libdisasm.so \ - $pkgdir/opt/nwn/nwmovies/libdis/libdisasm.so + # Compile nwlogger + cd "${srcdir}/nwlogger" + ./nwlogger_install.pl +} - # SymLink BinkPlayer to the NWN Directory so the Movie Launcher (nwmovies.pl) can find it - ln -s /usr/bin/binkplayer $pkgdir/opt/nwn/BinkPlayer +package() +{ + # Create Destination Directory + install -d "${pkgdir}/opt/" - ########################################################################### - # - # nwuser: - # - # Per-User Settings Support for NWN - # - ########################################################################### + # Install Base Game Files + mv "${srcdir}/gametmp/" \ + "${pkgdir}/opt/nwn" - # Compile nwuser - ./nwuser_install.pl + # Install Kingmaker Files + cp -r "${srcdir}/kingmakertmp/\$0/"* \ + "${pkgdir}/opt/nwn/" - # Install nwuser binaries - install -D -m 755 $srcdir/nwuser/nwuser.so \ - $pkgdir/opt/nwn/nwuser.so + # Check the Installation + cd "${pkgdir}/opt/nwn/" + ./fixinstall - # Install 64bit binaries if Arch64 - if [ "$CARCH" = "x86_64" ]; then - install -D -m 755 $srcdir/nwuser/nwuser64.so \ - $pkgdir/opt/nwn/nwuser64.so - fi + # Install Addons (nwmovies, nwuser, nwmouse, and nwlogger) + _install_addons - ########################################################################### - # - # nwmouse: - # - # Hardware Mouse Cursors Support for NWN - # - ########################################################################### + # Install CD Key File + install -D -m 0644 "${srcdir}/nwn.key" \ + "${pkgdir}/opt/nwn/nwncdkey.ini" - # Patch file so it can find user.h - /bin/sed -i 's|linux/user.h|sys/user.h|1' $srcdir/nwmouse/nwmouse_cookie.c + # Install Custom License + install -D -m 0644 "${srcdir}/EULA.txt" \ + "${pkgdir}/usr/share/licenses/${pkgname}/EULA.txt" - # Compile nwmouse - ./nwmouse_install.pl + # Install Launcher (Client) + install -D -m 0755 "${srcdir}/nwn.launcher" \ + "${pkgdir}/usr/bin/nwn" - # Install nwmouse binaries - install -D -m 755 $srcdir/nwmouse/nwmouse.so \ - $pkgdir/opt/nwn/nwmouse.so + # Install Desktop File + install -D -m 0644 "${srcdir}/nwn.desktop" \ + "${pkgdir}/usr/share/applications/nwn.desktop" - # Install libdis binaries - install -D -m 755 $srcdir/nwmouse/libdis/libdisasm.so \ - $pkgdir/opt/nwn/nwmouse/libdis/libdisasm.so + # Install Icon File + install -D -m 0644 "${srcdir}/nwn.ico" \ + "${pkgdir}/usr/share/pixmaps/nwn.ico" - ########################################################################### - # - # nwlogger: - # - # Client-Side Chat Window Logging Support for NWN - # - ########################################################################### + # Remove Unneeded Files & Directories + rm -r "${pkgdir}/opt/nwn/SDL-1.2.5/" - # Patch file so it can find user.h - /bin/sed -i 's|linux/user.h|sys/user.h|1' $srcdir/nwlogger/nwlogger_cookie.c + # Fix Whacky Permissions + chown -R root:root "${pkgdir}" + chmod -R o+r "${pkgdir}" +} - # Compile nwlogger - ./nwlogger_install.pl +_install_addons() +{ + cd "${srcdir}" - # Install nwlogger binaries - install -D -m 755 $srcdir/nwlogger/nwlogger.so \ - $pkgdir/opt/nwn/nwlogger.so + # Install nwmovies binaries + install -D -m 0755 -t "${pkgdir}/opt/nwn/" \ + "${srcdir}/nwmovies/"{nwmovies.so,nwmovies.pl} + + # Install binkplayer binaries + install -D -m 0755 "${srcdir}/nwmovies/nwmovies/binklib.so" \ + "${pkgdir}/opt/nwn/nwmovies/binklib.so" # Install libdis binaries - install -D -m 755 $srcdir/nwlogger/libdis/libdisasm.so \ - $pkgdir/opt/nwn/nwlogger/libdis/libdisasm.so + install -D -m 0755 "${srcdir}/nwmovies/nwmovies/libdis/libdisasm.so" \ + "${pkgdir}/opt/nwn/nwmovies/libdis/libdisasm.so" - ########################################################################### + # SymLink BinkPlayer to the NWN Directory so the Movie Launcher (nwmovies.pl) can find it + ln -s /usr/bin/binkplayer "${pkgdir}/opt/nwn/BinkPlayer" - # Install Cursors - install -d $pkgdir/opt/nwn/nwmouse/cursors/ - tar -zxvf $srcdir/cursors.tar.gz -C $pkgdir/opt/nwn/nwmouse/cursors/ + # Install nwuser binaries + install -D -m 0755 "${srcdir}/nwuser/nwuser/nwuser.so" \ + "${pkgdir}/opt/nwn/nwuser.so" - # Install Custom License - install -D -m 644 $_dvdpath/EULA.txt \ - $pkgdir/usr/share/licenses/$pkgname/EULA.txt + # Install 64bit binaries if Arch64 + if [ "$CARCH" = "x86_64" ]; then + install -D -m 0755 "${srcdir}/nwuser/nwuser/nwuser64.so" \ + "${pkgdir}/opt/nwn/nwuser64.so" + fi - # Install Launcher (Client) - install -D -m 755 $srcdir/nwn.launcher \ - $pkgdir/usr/bin/nwn + # Install nwmouse binaries + install -D -m 0755 "${srcdir}/nwmouse/nwmouse/nwmouse.so" \ + "${pkgdir}/opt/nwn/nwmouse.so" - # Install Desktop File - install -D -m 644 $srcdir/nwn.desktop \ - $pkgdir/usr/share/applications/nwn.desktop + # Install libdis binaries + install -D -m 0755 "${srcdir}/nwmouse/nwmouse/libdis/libdisasm.so" \ + "${pkgdir}/opt/nwn/nwmouse/libdis/libdisasm.so" - # Install Icon File - install -D -m 644 $_dvdpath/nwn.ico \ - $pkgdir/usr/share/pixmaps/nwn.ico + # Install nwlogger binaries + install -D -m 0755 "${srcdir}/nwlogger/nwlogger/nwlogger.so" \ + "${pkgdir}/opt/nwn/nwlogger.so" - # Fix Whacky Permissions - chown -R root:root $pkgdir/ - chmod -R o+r $pkgdir/ + # Install libdis binaries + install -D -m 0755 "${srcdir}/nwlogger/nwlogger/libdis/libdisasm.so" \ + "${pkgdir}/opt/nwn/nwlogger/libdis/libdisasm.so" + + # Install Cursors + install -d "${pkgdir}/opt/nwn/nwmouse/cursors/" + tar -zxvf "${srcdir}/nwmouse/nwmouse/cursors.tar.gz" -C \ + "${pkgdir}/opt/nwn/nwmouse/cursors/" } diff --git a/nwn.desktop b/nwn.desktop index 34f775cccbd0..291f0a5c2278 100644 --- a/nwn.desktop +++ b/nwn.desktop @@ -4,7 +4,7 @@ Name=Neverwinter Nights Diamond GenericName=Neverwinter Nights Comment=Play Neverwinter Nights Diamond Exec=/usr/bin/nwn -Icon=/usr/share/pixmaps/nwn.ico +Icon=nwn StartupNotify=true Terminal=false Type=Application diff --git a/nwn.install b/nwn.install index 9a4304d13759..70bd1d6904a1 100644 --- a/nwn.install +++ b/nwn.install @@ -1,24 +1,15 @@ - post_install() { - echo ">>> If you use software mixing on your sound card, uncomment the" - echo ">>> first export statement in /usr/bin/nwn to make that work" - echo ">>>" - echo ">>> Some of the additional modules create .ini files the first time" - echo ">>> they start. You may have to restart nwn a few times for it" - echo ">>> load successfully. This is normal. Run 'nwn' from a terminal the" - echo ">>> first few times until the game starts running correctly." -} - -post_upgrade() { - post_install $1 + echo "Before running Neverwinter Nights, you must edit /opt/nwn/nwncdkey.ini" + echo " and enter the 3 CD keys that came with your NWN Diamond DVD" + echo "" + + echo "Some of the additional linux modules create .ini files the first time" + echo " they start. You may have to run 'nwn' a few times for the game" + echo " load successfully. Run 'nwn' from a terminal initially so you can" + echo " inspect the output." + echo "" + + echo "If you use software mixing on your sound card, uncomment the" + echo " first export statement in /usr/bin/nwn" } -pre_remove() { - /bin/true -} - -op=$1 -shift - -$op $* - diff --git a/nwn.key b/nwn.key new file mode 100644 index 000000000000..b3fb966c813a --- /dev/null +++ b/nwn.key @@ -0,0 +1,9 @@ +;These are your CD Keys for Neverwinter Nights. +;DO NOT share these CD Keys with ANYONE. +;Apart from this installation, or when registering with the Official Neverwinter Nights Community Site [http://nwn.bioware.com], BioWare and Infogrames will NEVER ask you for this CD Key. + +[CDKEY] +Key3=Enter "Hordes of the Underdark" key here. +Key2=Enter "Shadows of Undrentide" key here. +Key1=Enter "Neverwinter Nights" key here. + diff --git a/nwn.launcher b/nwn.launcher index b0b3c0a89b62..1d65cef5143e 100644 --- a/nwn.launcher +++ b/nwn.launcher @@ -2,7 +2,7 @@ # Create user directory if it doesn't exist if [ ! -d "$HOME/.nwn/" ]; then - mkdir $HOME/.nwn/ + mkdir "$HOME/.nwn/" fi cd "/opt/nwn" |