Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Push out Firefox bookmarks to multiple users Post 302238063 by vino on Friday 19th of September 2008 01:03:35 AM
Old 09-19-2008
Quote:
Originally Posted by yodomino6
Ok, so I want to push out Firefox bookmarks to all the student accounts on my Mac server, but we all know how fun-loving Firefox profiles are, with their random czg6hi72.default profile names.

My question is how would I send the bookmarks.html file out to /Students/<username>/Library/Application Support/Firefox/Profiles/czg6hi72.default when the czg6hi72.default is going to be different for every account. Since that is the only folder in the Profiles folder, is there a way to say go into whichever folder is in the Profiles folder?

Please let me know if this doesn't make any sense.. even I'm getting confused!!
Thanks!
profile.ini holds the path

Code:
#! /bin/ksh
#
# /Students/<username>/Library/Application Support/Firefox/Profiles/czg6hi72.default

# path to bookmarks.html
#
bookmark=bkmk.html

for student in $(<list_of_students.txt)
do
  cd "/Students/${student}/Library/Application Support/FireFox"

  # Check for the default path in profile.ini
  # This should handle the IsRelative param as well
  #
  path=$(grep -Ei "^path" profile.ini)
  cd ${path}

  #backup the previous bookmarks
  #
  /bin/mv bookmarks.html bookmarks.html.$(date +%Y%m%d)
 
  # Deploy the new one
  #
  /bin/cp ${bookmark} .
done

Adapt this to suit your needs.

Last edited by vino; 09-19-2008 at 02:08 AM..
 

5 More Discussions You Might Find Interesting

1. Solaris

multiple displays of characters with one push of the key.

Hi, I have a Ultra5 440MHz system running Solaris 2.6 (Rev 5.6) and have a problem with the keyboard. When I push a key it prints characters very quickly. If I push a key very fast I get maybe 3 characters. So, I am thinking bad keyboard. I borrow a known good keyboard, samething and the... (3 Replies)
Discussion started by: mndavies
3 Replies

2. UNIX for Advanced & Expert Users

How to install firefox extensions for all users

Hello, I am wondering the "new way" to install firefox extensions for all users. From https://developer.mozilla.org/En/Command_Line_Options we can see that the "old way" is no longer available. I'm using the Lucid UNE to write this and note that it has these extensions installed for every... (3 Replies)
Discussion started by: Narnie
3 Replies

3. UNIX and Linux Applications

install multiple versions of firefox in linux

Since apt-get and yum won't let you install multiple versions of firefox I will explain how to here. 1. Go to this page and decide which version of firefox you want. ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/ I used this one. ... (0 Replies)
Discussion started by: cokedude
0 Replies

4. UNIX and Linux Applications

Firefox Warning message for closing with multiple tabs not working

Can anyone explain why firefox warning message for closing with multiple tabs not working. The checkbox for warning when you have multiple tabs is checked so I don't understand why its not working. (0 Replies)
Discussion started by: cokedude
0 Replies

5. Shell Programming and Scripting

Create multiple users with individual passwords to users

hi, i am new to shell scripts i write a shell script to create multiple users but i need to give passwords to that users while creating users, command to write this script (1 Reply)
Discussion started by: DONFOX
1 Replies
RMF(1)								     [nmh-1.5]								    RMF(1)

NAME
rmf - remove an nmh folder SYNOPSIS
rmf [+folder] [-interactive | -nointeractive] [-version] [-help] DESCRIPTION
Rmf removes all of the messages (files) within the specified (or default) folder, and then removes the folder (directory) itself. If there are any files within the folder which are not a part of nmh, they will not be removed, and an error will be produced. If the folder is given explicitly or the -nointeractive option is given, then the folder will be removed without confirmation. Otherwise, the user will be asked for confirmation. If rmf can't find the current folder, for some reason, the folder to be removed defaults to `+inbox' (unless overridden by user's profile entry "Inbox") with confirmation. If the folder being removed is a subfolder, the parent folder will become the new current folder, and rmf will produce a message telling the user this has happened. This provides an easy mechanism for selecting a set of messages, operating on the list, then removing the list and returning to the current folder from which the list was extracted. If rmf s used on a read-only folder, it will delete all the (private) sequences (i.e., "atr-seq-folder" entries) for this folder from your context without affecting the folder itself. Rmf irreversibly deletes messages that don't have other links, so use it with caution. FILES
$HOME/.mh_profile The user profile PROFILE COMPONENTS
Path: To determine the user's nmh directory Current-Folder: To find the default current folder Inbox: To find the default inbox SEE ALSO
rmm(1) DEFAULTS
`+folder' defaults to the current folder, usually with confirmation `-interactive' if +folder' not given, `-nointeractive' otherwise CONTEXT
Rmf will set the current folder to the parent folder if a subfolder is removed; or if the current folder is removed, it will make "inbox" current. Otherwise, it doesn't change the current folder or message. BUGS
Although intuitively one would suspect that rmf works recursively, it does not. Hence if you have a sub-folder within a folder, in order to rmf the parent, you must first rmf each of the children. MH.6.8 11 June 2012 RMF(1)
All times are GMT -4. The time now is 01:56 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy