From ae3edf8905294ac471503692af8c8aa92ba85fc2 Mon Sep 17 00:00:00 2001 From: Phil Davis Date: Thu, 6 Aug 2015 12:48:39 +0545 Subject: Notes package code style --- config/notes/notes.inc | 42 +++++++++++---------------- config/notes/notes.xml | 78 +++++++++++++++++++++++++------------------------- 2 files changed, 56 insertions(+), 64 deletions(-) (limited to 'config/notes') diff --git a/config/notes/notes.inc b/config/notes/notes.inc index f4bfe2cc..29b51396 100644 --- a/config/notes/notes.inc +++ b/config/notes/notes.inc @@ -3,10 +3,10 @@ /* /* ========================================================================== */ /* - notes.inc - Copyright (C) 2008 Mark J Crane - All rights reserved. - */ + notes.inc + Copyright (C) 2008 Mark J Crane + All rights reserved. +*/ /* ========================================================================== */ /* Redistribution and use in source and binary forms, with or without @@ -31,61 +31,53 @@ POSSIBILITY OF SUCH DAMAGE. */ -function notes_sync_package() -{ - - //global $config; +function notes_sync_package() { + + //global $config; } - -function notes_install_command() -{ + +function notes_install_command() { global $config; conf_mount_rw(); config_lock(); if (!is_dir('/usr/local/www/packages/')) { - exec("mkdir /usr/local/www/packages/"); + exec("mkdir /usr/local/www/packages/"); } - + //if (!is_dir('/usr/local/www/packages/notes/')) { // exec("mkdir /usr/local/www/packages/notes/"); //} - //rename PHP files from .tmp to .php //exec("cp /tmp/notes.tmp /usr/local/www/packages/phpservice/notes.php"); //unlink_if_exists("/tmp/notes.tmp"); - - //write_config(); + //write_config(); - //write_rcfile(array( // "file" => "notes.sh", // "start" => "/usr/local/bin/php /usr/local/pkg/notes.php", // "stop" => "rm /tmp/phpmonitor.pid" // ) //); - - + notes_sync_package(); - - //if (pkg_is_service_running('notes')) { + //if (pkg_is_service_running('notes')) { //documentation purposes //} conf_mount_ro(); config_unlock(); - + } -function notes_deinstall_command() -{ +function notes_deinstall_command() { conf_mount_rw(); config_lock(); @@ -93,7 +85,7 @@ function notes_deinstall_command() unlink_if_exists("/usr/local/pkg/notes.inc"); conf_mount_ro(); config_unlock(); - + } ?> \ No newline at end of file diff --git a/config/notes/notes.xml b/config/notes/notes.xml index 513bf922..34d2f676 100644 --- a/config/notes/notes.xml +++ b/config/notes/notes.xml @@ -2,46 +2,46 @@ - - + - - Notes - Describe your package requirements here - Currently there are no FAQ items provided. + ]]> + + Notes + Describe your package requirements here + Currently there are no FAQ items provided. Notes - 0.2.3 + 0.2.5 Settings /usr/local/pkg/notes.inc @@ -56,24 +56,24 @@ Settings /pkg_edit.php?xml=notes.xml - + - installedpackages->package->$packagename->configuration->notes + installedpackages->package->$packagename->configuration->notes /usr/local/pkg/ - 0755 + 0755 https://packages.pfsense.org/packages/config/notes/notes.inc Title title - + Category category - + Title @@ -86,7 +86,7 @@ category Enter a category. input - + <b>Notes</b> <br /> <br /> notes @@ -94,16 +94,16 @@ textarea base64 30 - 70 + 70 20 - + notes_sync_package(); - + notes_sync_package(); -- cgit v1.2.3