Hi,
I have a requirement that i need to store only the filename without its extension. Can anyone please help me to do this.
For Example, i have stored the filename in a varialble called fname. I need to extract all the charecters before the first occurence of the dot.
If fname has value... (3 Replies)
Hi,
Any help on this would be very appreciated.
I capture the full path & filename in a variable like (varFile=/home/user/extfile.txt). Now in my shell script I have to use only the filename part i.e. extfile.txt. How do I extract only the filename part from the variable?
Thanks in... (3 Replies)
I need to extract the date part from the file name (20080221 in this ex) and compare it with the current date and delete it, if it is a past date.
$file = exp_ABCD4_T-2584780_upto_20080221.dmp.Z
really appreciate any help.
thanks
mkneni (4 Replies)
Hi,
I need to extract the file name without filetype.
Suppose in DIR1 if i have files like F1.txt and F2.DOC then i need to return F1 and F2 only with out file types (txt and DOC).
I tried with the following code
newname = ` $i | cut -d "'." -f1`
but it is giving the error " 0403-006... (1 Reply)
hi all,
I'm trying to automate some tasks and while I've got the script itself working, I'm having difficulties with automatic file detection and associated variable setting...
for example, in a directory I've got several files... something along the lines of:
xis0_NAME_src.file... (2 Replies)
I am using ksh93 on Solaris.
Ok, this may seem like a simple request at first. I have a directory that contains sets of files with a YYYYMMDD component to the name, along with other files of different filespecs. something like this:
20110501_1.dat
20110501_2.dat
20110501_3.dat... (2 Replies)
Hi
I would like to extract the first portion of filename from a list of files.
The filename pattern is of the form 123456789_TEXT_TEXT_TEXT_.csv. I want to extract just the numerical portion of this filename from the list of files and then output this into another text file.
K (6 Replies)
Hello,
I'd like to write a monthly archive script that archives some logs. But I'd like to do it based on yesterday's date. In other words, I'd like to schedule the script to run on the 1st day of each month, but have the archive filename include the previous month instead.
Here's what I... (5 Replies)
Suppose i have a list of files in a directory as mentioned below
1. Shankar_04152019_ny.txt
2. Gopi_shan_03122019_mi.txt
3. Siva_mourya_02242019_nd.txt
..
.
.
.
.
1000 . Jiva_surya_02282019_nd.txt
query : At one shot i want to modify the above all filenames present in one path with... (4 Replies)
I am using bash and have a filename with a path and extension and want to extract just the filename
Have used the following code, oflna gives the file name with extension, but now neet to remove the .texi at the end.
oflna=${flnm##*/}
oflnb=${${flnm##*/}%.*}
echo "flnm: $flnm"
echo... (1 Reply)
Discussion started by: Danette
1 Replies
LEARN ABOUT DEBIAN
theme
THEME(1) BSD General Commands Manual THEME(1)NAME
theme -- create a web page from a template file
SYNOPSIS
theme [-d root] [-E] [-f] [-o file] [-p pagename] [-t template] [-V] [textfile]
DESCRIPTION
The theme utility takes a markdown(7)-formatted textfile (or stdin if not specified,) compiles it, and combines it with a template
(page.theme by default) to produce a web page. If a path to the template is not specified, theme looks for page.theme in the current direc-
tory, then each parent directory up to the document root (set with -d or, if unset, the root directory of the system.) If page.theme is
found, theme copies it to the output, looking for <?theme action?> html tags and processing the embedded action as appropriate.
theme processes the following actions:
author Prints the author name(s) from the mkd_doc_author(3) function.
body Prints the formatted markdown(7) input file.
date Prints the date returned by mkd_doc_date(3) or, if none, the date the input file was last modified.
dir Prints the directory part of the pagename
include(file)
Prints the contents of file. Markdown(7) translation will NOT be done on this file.
source The filename part of the pagename.
style Print any stylesheets (see mkd-extensions(7)) found in the input file.
title Print the title returned by mkd_doc_title(3), or, if that does not exist, the source filename.
version Print the version of discount(7) that this copy of theme was compiled with.
If input is coming from a file and the output was not set with the -o option, writes the output to file-sans-text.html (if) file has a .text
suffix, that will be stripped off and replaced with .html; otherwise a .html will be appended to the end of the filename.)
The options are as follows:
-d root Set the document root to root
-E Normally theme will not expand <?theme body?> or <?theme toc?> in the <head> section, or <?theme style?> in the <body> section, but
the -E option overrides this and allows expansions everywhere.
-f Forcibly overwrite existing html files.
-o filename
Write the output to filename.
-p path Set the pagename to path.
-t filename
Use filename as the template file.
RETURN VALUES
The theme utility exits 0 on success, and >0 if an error occurs.
SEE ALSO markdown(1), markdown(3), markdown(7), mkd-extensions(7).
AUTHOR
David Parsons (orc@pell.chi.il.us)
MASTODON January 23, 2008 MASTODON