aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2003-01-14 04:48:12 +0000
committerBill Nottingham <notting@redhat.com>2003-01-14 04:48:12 +0000
commitc913d33c793e1de6b902445b96a7de9451a107b0 (patch)
tree291c1d7001706bc7f1ef99c876d446e433a1a56e
parenta0266b9b4f1b8e1906fd5ff198562be755574089 (diff)
downloadinitscripts-c913d33c793e1de6b902445b96a7de9451a107b0.tar
initscripts-c913d33c793e1de6b902445b96a7de9451a107b0.tar.gz
initscripts-c913d33c793e1de6b902445b96a7de9451a107b0.tar.bz2
initscripts-c913d33c793e1de6b902445b96a7de9451a107b0.tar.xz
initscripts-c913d33c793e1de6b902445b96a7de9451a107b0.zip
rework halt script (#76831, <michal@harddata.com>)
-rwxr-xr-xrc.d/init.d/halt7
1 files changed, 4 insertions, 3 deletions
diff --git a/rc.d/init.d/halt b/rc.d/init.d/halt
index 9c27a847..b9c082b3 100755
--- a/rc.d/init.d/halt
+++ b/rc.d/init.d/halt
@@ -23,9 +23,10 @@ runcmd() {
}
halt_get_remaining() {
- awk '!/(^#|proc|loopfs|autofs|devfs|^none|^\/dev\/root| \/ )/ {print $2}' /proc/mounts
- awk '{ if ($3 ~ /^proc$/ && $2 !~ /^\/proc/) print $2; }' /proc/mounts
- awk '{ if ($3 ~ /^tmpfs$/ && $2 !~ /^\/dev/) print $2; }' /proc/mounts
+ awk '$2 ~ /^\/$|^\/proc|^\/dev/{next}
+ $3 == "tmpfs" || $3 == "proc" {print $2 ; next}
+ /(^#|loopfs|autofs|devfs|^none|^\/dev\/root)/ {next}
+ {print $2}' /proc/mounts
}
# See how we were called.
ref='#n172'>172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389
services:
    notification_manager:
        class: phpbb\notification\manager
        arguments:
            - @notification.type_collection
            - @notification.method_collection
            - @service_container
            - @user_loader
            - @config
            - @dbal.conn
            - @cache
            - @user
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%

# ----- Notification's types -----
# Scope MUST be prototype for all the plugins to work.
    notification.type_collection:
        class: phpbb\di\service_collection
        arguments:
            - @service_container
        tags:
            - { name: service_collection, tag: notification.type }

    notification.type.approve_post:
        class: phpbb\notification\type\approve_post
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.approve_topic:
        class: phpbb\notification\type\approve_topic
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.bookmark:
        class: phpbb\notification\type\bookmark
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.disapprove_post:
        class: phpbb\notification\type\disapprove_post
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.disapprove_topic:
        class: phpbb\notification\type\disapprove_topic
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.group_request:
        class: phpbb\notification\type\group_request
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.group_request_approved:
        class: phpbb\notification\type\group_request_approved
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.pm:
        class: phpbb\notification\type\pm
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.post:
        class: phpbb\notification\type\post
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.post_in_queue:
        class: phpbb\notification\type\post_in_queue
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.quote:
        class: phpbb\notification\type\quote
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.report_pm:
        class: phpbb\notification\type\report_pm
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.report_pm_closed:
        class: phpbb\notification\type\report_pm_closed
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.report_post:
        class: phpbb\notification\type\report_post
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.report_post_closed:
        class: phpbb\notification\type\report_post_closed
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.topic:
        class: phpbb\notification\type\topic
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.topic_in_queue:
        class: phpbb\notification\type\topic_in_queue
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }

    notification.type.admin_activate_user:
        class: phpbb\notification\type\admin_activate_user
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
            - %tables.notification_types%
            - %tables.notifications%
            - %tables.user_notifications%
        tags:
            - { name: notification.type }
            
# ----- Notification's methods -----
# Scope MUST be prototype for all the plugins to work.
    notification.method_collection:
        class: phpbb\di\service_collection
        arguments:
            - @service_container
        tags:
            - { name: service_collection, tag: notification.method }

    notification.method.email:
        class: phpbb\notification\method\email
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
        tags:
            - { name: notification.method }

    notification.method.jabber:
        class: phpbb\notification\method\jabber
        scope: prototype
        arguments:
            - @user_loader
            - @dbal.conn
            - @cache.driver
            - @user
            - @auth
            - @config
            - %core.root_path%
            - %core.php_ext%
        tags:
            - { name: notification.method }