Sponsored Content
Top Forums Shell Programming and Scripting Creating dated folder name in SMB share Post 303001827 by sdch1000 on Friday 11th of August 2017 05:32:59 PM
Old 08-11-2017
Creating dated folder name in SMB share

I can't seen to figure this out. Let's say I want to create a folder with the name "August2017". In regular terminal prompt I can type
Code:
mkdir `date +%B%Y`

But when I'm connected to a SMB share (at the smb: prompt), the command doesn't translate properly. A folder gets created but the name is `date

What's the correct syntax to get this working?

Thanks!
Moderator's Comments:
Mod Comment Please use CODE tags (not B tags) when displaying sample input, output, and code segments.

Last edited by Don Cragun; 08-11-2017 at 07:07 PM.. Reason: Change B tags to CODE and ICODE tags.
 

9 More Discussions You Might Find Interesting

1. Linux

how i can share from fc5 folder

hai friends i am using fc5 i configured samba and i can access windows files and folders in my network of linux. but in windows(xp.2000) i can not access my fc5 folder. pls x-xplain me anybody what i need to do in gui of fc5 for to enable to share my files and folders to windows(my samba... (0 Replies)
Discussion started by: sadiquep
0 Replies

2. HP-UX

How to Share out a folder in Hp UX 10.20 OS

Hi all, I'm new to UNIX and recently i just being assign to work with a HP UX 10.20 Operation Systems. So i wonder if i can share out some folder in the system as this UNIX is link to another Windows base PC. My purpose is to do some auto file maintenance where i can copy/delete files in UNIX... (1 Reply)
Discussion started by: sim2004
1 Replies

3. Solaris

how to share a folder from windows xp to solaris 8

how to share a folder from windows xp to solaris 8? with out using samba?it is possible or not for sharing a folder between windows and solaris 8 (1 Reply)
Discussion started by: tv.praveenkumar
1 Replies

4. Shell Programming and Scripting

Apache/CGI Bin Accessing mounted SMB share

Hey Guys, I need to copy some files from my Apache server to SMB share ... copy $file,"/Volumes/v1/x/test/$datestamp$name$suffix" Unfortunately this command when executed from Apache/cgi-bin is not able to access mounted volumes .. is there anything that can be done about that ... Can... (1 Reply)
Discussion started by: NDxiak
1 Replies

5. Solaris

mounting windows share folder

please help me,,i need step to mount windows share folder,,i try samba and nfs and it didnt work (in my linux server the command is fine),,can somenone give me an example for this to be done? (0 Replies)
Discussion started by: Cellscript
0 Replies

6. Solaris

mount windows share folder

all,,i need help,,i try to mount a windows 2000 share folder to my system,,i already userd smb mount,mount -F and bunch of stuff and none is working,,can anyone give me a script to this?? PS : when i use mount -F i got this message : nfs mount: insufficient privileges ,,, is it must be root ? (6 Replies)
Discussion started by: Cellscript
6 Replies

7. OS X (Apple)

SMB Connection Resolve to AD, Point to User Share

I've got an unusual problem that deals with connecting via SMB under Snow Leopard, to a directory share with over 1,000 users. When I connect to the main directory share, the next level reveals 1,000 users, but I'd like to have the connection identify me as a registered user in AD at the time of... (0 Replies)
Discussion started by: unimachead
0 Replies

8. Solaris

creating a share file

Hello Solaris Gurus, can anyone please explain to me how to create a share file to share across network? Thanks (2 Replies)
Discussion started by: cjashu
2 Replies

9. Solaris

auto mount SMB share on Solaris 10

I CANNOT use autmounter so should I just write the command as an /etc/rc script or is it possible to auto mount the share via the vfstab? (4 Replies)
Discussion started by: LittleLebowski
4 Replies
whatnow(1mh)															      whatnow(1mh)

Name
       whatnow - prompting front-end for send

Syntax
       whatnow [ options ] [ file ]

Description
       After  you  have  finished  editing a draft message in or the program prompts you for the next required action.	Press <Return> at the What
       now? prompt to see a list of the available responses.  These responses are:
       display [options]
       edit [editor] [options]
       list [options]
       push [options]
       quit [-delete]
       refile [options] +folder
       send  [options]
       whom  [options]
       For more information on the options available with these commands, see the following reference pages:

       Use display if you have been using or and want to see the original message.  Use edit if you want to continue editing the draft.  Use  list
       to display the draft message.  If you use push, operates in the background and frees your terminal while the message is being sent.

       Use quit to exit from and to save the draft message.  The -delete option to quit will exit from and delete the draft message.

       Use  refile +folder to refile the draft message in a specified folder.  The send response will cause the message to be delivered.  Use whom
       to find out who will receive the mail when it is sent.

       Unless the -noedit option is given, the editor starts when is invoked.

       For the edit response, you can specify an editor if you wish to override the editor specified in your (R)file.  If you  specify	an  editor
       with  the edit response, any valid option to the editor is valid.  Similarly, for the send and whom responses, any valid option to send and
       whom commands, respectively, are valid.

       For the push response, use any valid option to MH invokes with the -push option.

       For the refile response, any valid option to the is valid.  The is the element of your mail profile  which  defines  the  program  used	to
       refile messages in another folder.  For more information, see

       For  the display and list responses, any valid argument to the is valid.  If any non-option arguments are present, then the pathname of the
       draft is excluded from the argument list given to the (this is useful for listing another MH message).  The is the  element  in	your  mail
       profile which defines the program used to display draft messages on your screen.  For more information, see

       See  for further information about how editors are used by MH.  It also describes and and shows how complex variables can be used to direct
       the actions performed by

       Although is usually invoked by other commands, you can use it as a separate command.  You can run on a named file by specifying the file as
       the  file argument.  If you do not give an absolute pathname (one beginning with a / or ./ or ../ ), assumes that the named file is in your
       current working directory.  If you want to run on an existing message, use the -draftfolder and -draftmessage options.

Options
       -draftfolder +folder
       -nodraftfolder
		 Specifies the folder in which searches for the draft message.	By default, the current message in the named folder is	used.	If
		 you wish to specify another message, use the -draftmessage option.  For more information on using a draft folder, see The -draft-
		 folder option can be set up in your user profile; see for more information.

       -draftmessage msg
		 Specifies the draft message to be used.  If you specify a folder with the -draftfolder option, the -draftmessage option takes the
		 number  of a message in that folder.  If you do not specify a folder, -draftmessage takes the name of a file.	If you do not give
		 an absolute pathname (one beginning with a / or ./ or ../ ), -draftmessage assumes that the file is located in your  Mail  direc-
		 tory.	(This is different from the file argument to which assumes that the file you name is in your current working directory.)

       -editor editorname
		 Specifies  the  name  of  the	editor you want to use to edit the draft message.  Any legal ULTRIX editor can be specified.  This
		 option is used only if you select the edit response to the What now? prompt.

       -help	 Prints a list of the valid options for this command.

       -noedit	 Prevents the initial invocation of an editor when an MH command is run.  Normally, when you enter an MH command such  as  or  the
		 program  is  called to start the initial edit of the draft message.  If you add this option to the whatnow entry in your the ini-
		 tial edit of the draft message is disabled.  This is a convenient way of disabling this edit for all  MH  commands,  rather  than
		 adding the -noedit entry to the entries for the individual commands in

       -prompt string
		 Specifies the prompt used by The prompt you receive when you invoke can be specified as a string with this option.  If the prompt
		 contains spaces, you must enclose the entire string in double quotes (" ").  The default prompt is What now?

Restrictions
       If the sendproc entry in your is uses a built-in program rather than running the regular If you	define	your  own  sendproc  program,  you
       should not not call it as will not run it.

Examples
       In the following example, takes the current message in the folder and asks what you want to do with it:
       % whatnow -draftfolder +drafts
       What now?

       In the following example, takes message 6 from the folder
       % whatnow -draftfolder +drafts -draftmessage 6
       What now?

       The following example sets the prompt to be Now What?:
       % whatnow -prompt "Now What?"
       Now what?

Profile Components
       Path:		  To determine your MH directory
       Draft-Folder:	  To find the default draft folder
       Editor:		  To override the default editor
       lasteditor-next:   To name an editor to be used after
			  exit from lasteditor
       fileproc:	  Program to refile the message
       lproc:		  Program to list the contents of a message
       sendproc:	  Program to send the message
       whomproc:	  Program to determine who a message would go to

Files
       The user profile.

See Also
       comp(1mh), send(1mh), whom(1mh)

																      whatnow(1mh)
All times are GMT -4. The time now is 05:31 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy