473,769 Members | 2,249 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Can anyone help me with shell script(find a file and email)

3 New Member
Hi i am new to unix. just trying to work my things out.

i have a small problem.
i needed to search for a file that is created mostly first week of every month and email it to a list.... can some one please help me with a script to do so.....

thanks in advance.....
pradeep
Jul 28 '08 #1
2 1786
gpraghuram
1,275 Recognized Expert Top Contributor
You should use find command and the mailx command to do this.
Check the man page of find command to to get some idea baout the find command.


raghu
Jul 29 '08 #2
sicarie
4,677 Recognized Expert Moderator Specialist
If the file is in a standard location and uses a naming convention (if this is automatically generated, it's likely that the naming convention would be something like 'filename-date' in which case you could just code your script to determine this month's file and send it out.

Of course, this is dependent on there not being any other files in the directory with this name, and that name being standard each month.
Jul 29 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

2
5979
by: J. Kingsley | last post by:
I am loading XML data into a SQL Server database using SQLXML with bulkload. I use a VB script file to perorm the load with the map schemas and the XML files. To do the load manually, you just double click on the VB script file which lies in a directory on the hard drive. Now I want to execute this file from a VB application or a Windows service. How do I call, reference or execute the file from VB.net?
6
1701
by: Mellow Crow | last post by:
Just discovered this technique. Is this old hat? Would there be any disadvantage to doing this? In your external .js file: /* Summary: includes external scripts in this external script so that you don't have to reference them within the (x)html document files.
2
265
by: Jason | last post by:
Hi I would like to create a .NET app that can receive an SQL script file as input. it will take the script file and execute it on the database, depending on what connection properties were entered by the user. best way? Thanks Jason
2
8603
by: Tumurbaatar S. | last post by:
Hi! I cannot imagine how to create db from a script file and execute other DDL statements on this new db. Currently I use 'psql -f file' to perform all needed DDL statements except of create db. Because when I insert 'CREATE DATABASE' at the beginning of the script, the server creates a db but following commands like 'CREATE TABLE' and etc run on the current db, i.e. not in context of newly created db. Any ideas? P.S. Some RDBMS...
18
6720
by: mollyf | last post by:
I just installed SQL Server 2005 on my PC (the developer's edition) yesterday. I have some scripts written by one of my coworkers to create some tables and stored procedures in a database that I've already created on my computer. Whenever I go to open the script file (whose icon shows that it's a SQL Server Query File and I've got the file type set to open with SQLWB - SQL Server Management Studio), the file opens in Notepad instead of...
1
3109
by: Larry Rebich | last post by:
I'm using some Java Script I found that supports a 'back' button on my ASP.Net page. The Asp.Net page uses a Master page. I thought I'd put the Java Script in a Java Script file . The thought was that I could use this script in other pages. So I put a reference to the script file in the <head tag of the Master page. But that does not work because the <head tag of the Master page also contains a 'runat=server' statement. And only one <head...
2
6098
by: prakashpb | last post by:
Hello All, I am new to perl. I have to write some code in perl on windows. I have to invoke/run a shell file sample.sh from within perl file. When the perl while is executing, it should run to set some env variables. Another requirement is that: I want to invoke cygwin shell from perl and then run some commands like cd, ls on the cygwin window. All this to be done by invoking through the running perl script.
10
1428
by: spacebebop | last post by:
#include <cstring> #include <iostream> using namespace std; class X { public: X(); X( char * ); ~X();
2
1055
by: Sheena777 | last post by:
how do you pass parameters to a script file? I want to pass values from a vb.net textbox to vb script file. The whole point of this is to be able to run the validation of the control from the script file.
1
2054
by: looza | last post by:
Hi All, I have a bunch of shell script files that use a common shell script file that contains certain global variables that are declared and initialized or derived by some arithmatic. I have to now convert one of the shell script file to a perl file so I can use the in-built functions. Is the a way I can import the file with the globals and use them in my perl script? Thanks!
0
9590
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10223
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10051
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9866
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8879
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7413
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5310
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3968
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2815
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.