Help with writing .bashrc file

I would like help with writing a .bashrc file.
The only thing I want right now is colored output and slashes for directories like what "ls -GF" does -- for each new terminal window.
Can you guys give me a hand?
Running Mac OS 10.4.6. Bash is default shell.
Thanks.

Hi Paul,
   You can get Apple's "ls" command to always output color with the following in your .bashrc:
export CLICOLOR=""
You can have an effect on the colors used with settings like the following:
export LSCOLORS="gxfxcxdxbxegedabafacad"
   I have a color prompt in my bash startup scripts, bashrc.tgz. If you unpack the tarball in the root of your home directory, the files will be put in a ~/Library/init/bash directory. The file named "prompt" sets the color prompt string.
Gary
~~~~
   I know you think you thought you knew what you
   thought I said, but I'm not sure you understood what
   you thought I meant.

Similar Messages

  • Help with writing to file

    Hi,
    How would I write to the same file between different classes? Is it possible to just make a static writer class and then any class can call its function to write? Any help would be appreciated.

    This is exactly it. Thanks so much.You're welcome.

  • Help with writing a batch file

    Hi :
    does anyone know anyplace online that I can get help in writing batch files?? I have never worked much with batch files before....
    any help is greatly appreciated
    thnx

    I suppose, since you're in a Java forum, you need batch files to load java applications.
    If you use windows :
    go to ms console (start/run/"cmd")
    type edit mybatch.bat
    write your command to load a java application, something like
    java myclass.class
    save and exit.
    Be sure the bat file and the class are in the same folder.
    And make certain you've set the classpath, and path variables correctly.
    If this was what you needed and you need more help just ask.
    (In this case it could be better to make executable jars)
    If you wanted to know about linux batches, it works pretty the same way.

  • Help with writing and retrieving data from a table field with type "LCHR"

    Hi Experts,
    I need help with writing and reading data from a database table field which has a type of "LCHR". I have given an example of the original code but don't know what to change it to in order to fix it and still read in the original data that's stored in the LCHR field.
    Basically we have two Function modules, one that saves list data to a database table and one that reads in this data. Both Function modules have an identicle table which has an array of fields from type INT4, CHAR, and type P. The INT4 field is the first one.
    Incidentally this worked in the 4.7 non-unicode system but is now dumping in the new ECC6 Unicode system.
    Thanks in advance,
    C
    SAVING THE LIST DATA TO DB
    DATA: L_WA(800).
    LOOP AT T_TAB into L_WA.
    ZDBTAB-DATALEN = STRLEN( L_WA ).
    MOVE: L_WA to ZDBTAB-RAWDATA.
    ZDBTAB-LINENUM = SY-TABIX.
    INSERT ZDBTAB.
    READING THE DATA FROM DB
    DATA: BEGIN OF T_DATA,
                 SEQNR type ZDBTAB-LINENUM,
                 DATA type ZDBTAB-RAWDATA,
               END OF T_TAB.
    Select the data.
    SELECT linenum rawdata from ZDBTAB into table T_DATA
         WHERE repid = w_repname
         AND rundate = w_rundate
         ORDER BY linenum.
    Populate calling Internal Table.
    LOOP AT T-DATA.
    APPEND T_DATA to T_TAB.
    ENDLOOP.

    Hi Anuj,
    The unicode flag is active.
    When I run our report and then to try and save the list data a dump is happening at the following point
    LOOP AT T_TAB into L_WA.
    As I say, T_TAB consists of different fields and field types whereas L_WA is CHAR 800. The dump mentions UC_OBJECTS_NOT_CONVERTIBLE
    When I try to load a saved list the dump is happening at the following point
    APPEND T_DATA-RAWDATA to T_TAB.
    T_DATA-RAWDATA is type LCHR and T_TAB consists of different fields and field types.
    In both examples the dumps mention UC_OBJECTS_NOT_CONVERTIBLE
    Regards
    C

  • Help with writing a formula

    Hi all,
    I am creating a report, and need help with writing a formula...
    I am creating a report that shows how many visits/touches our reps have made to various grade accounts. It is broken down by calendar week, and I currently have a weekly "goal" number set that the reps have to meet. That "goal" number increases each week to keep a running total. (example: week 1: 7, week 2: 14, week 3: 21)
    I have created some different formulas and one is this:
    SUM("Activity Metrics"."# of Activities" BY Date."Calendar Week")
    What this shows me is how many "visits" there are per calendar week to customers, however it show me the total for all reps per week.
    What I need is that total to show, but totaled for each rep individually.
    What I was trying is this:
    SUM("Activity Metrics"."# of Activities" BY Date."Calendar Week") BY Employee."Employee Name"
    But...I keep getting an error.
    Any suggestions?
    I have the reporting book by Lairson, and have been referring to it...but my brain at this point is fried.
    Thanks in advance for any help...(please forgive...I am new to OnDemand, and I am sure this is easy)

    Thanks for helping!
    I created this formula as a column: SUM ("Activity Metrics"."# of Activities" BY Date."Calendar Week"), it is called "total number of visits per week" and it shows the totaled number of visits that all the reps have done per calendar week. For example: Week 1: 10 visits, Week 2: 37 visits, Week 3: 20 visits.
    What I would like to do is take that column and break it down further, to show instead how many visits per week by sales rep there have been
    So what I was trying was to take the "total number of visits per week" (SUM ("Activity Metrics"."# of Activities" BY Date."Calendar Week")) and use "Activity Owner" (Employee."Employee Name") to break it down further.
    What I need to use is the total number of visits each rep has per calendar week.
    I think I am getting the error because you can't use "BY" twice in a formula?

  • I need help with a PDF file that is an image, the "Read Out Loud' option does not work, please help!

    I need help with a PDF file that is an image, the "Read Out Loud' option does not work, please help!

    You mean an image such as a scanned document?
    If that is the case, the file doesn't contain any text for Reader Out Loud to read. In order to fix that, you would need an application such as Adobe Acrobat that does Optical Character Recognition to convert the images to actual text.
    You can also try to export the file as a Word document or something else using ExportPDF which I believe offers OCR and is cheaper than Acrobat.

  • Help with writing, reading a file...

    I'm writing a program that writes a number to a file and then reads it again each time it is loaded. It's like a counter, the number starts out being 0, then when the program is run again the number will be two, and so on and so on. I've never been good with writing incrementer type things and files, so could you help me out? Remember, the program writes a single number to the file, and then adds one to that number each time the program is run, so it starts at zero and goes up by one each time it is run.
    -Thanks... I just came back from vacation and my Java skills are somewhat lacking :P

    open old file -> get the number -> create a new file -> write new number

  • Please help with writing a class

    i need help getting started with this assignment. i haven't done anything with writing classes, so i don't know where to start.
    i need to create a bank account class that will keep a name, balance, up to 50 deposits, and up to 50 withdrawls. i need to include 2 arrays for the deposits and withdrawls.
    Here's what i know:
    I need a constructor that takes zero arguments. This constructor would initialize the numeric value to zero.
    I need a 2nd constructor that takes one argument, a name as a String value. This constructor would initialize the numeric value to zero.
    I need a 3rd constructor that takes two arguments, a name as a String value and a starting "balance" as a double value

    Sorry, I was watching a movie with my wife ...imagine that. Study my examples here and try to understand what I have done. You will follow the same methodology for the rest of the program. Use main to test the methods in your program.
    public class mdlAccount {
      String name;
      double balance;
      int currentDeposit = 0;
      int currentWithdrawl = 0;
      double[] deposits = new double[50];
      double[] withdrawals = new double[50];
      public mdlAccount() {
        name = "";
        balance = 0.0;
      public mdlAccount(String name) {
        this.name = name;
        balance = 0.0;
      public mdlAccount(String name, double balance) {
        this.name = name;
        this.balance = balance;
      // When the instructor says: Have a method that does deposits...
      // You need to create a method, similar to the constructors,
      // but with a return value, even if it returns void (nothing).
      // Like this:
      public void deposit( double amount ) {
        // Do some error checking.
        if ( currentDeposit < 50 && amount > 0 ) { // > is a greater than sign
          // If all is ok, add to the balance...
          balance += amount;
          // and add the entry to the array of deposits
          deposits[currentDeposit] = amount;
          // Finally, add 1 to the currentDeposit variable.
          currentDeposit++;
      // We need the 'return the balance' method so we can see if
      // the program runs correctly. This time we return a double,
      // instead of void. (void means don't return anything at all).
      public double getBalance() {
        return balance;
    // Now you create the next method for withdrawals...
    //  if ( currentWithdrawl < 50 ) {
    //    deposits[currentWithdrawl] = amount;
    //    currentWithdrawl++;
      // You want a main method so this class can be executed.
      // You can remove it later if you want to use this class
      // from within another larger program.
      public static void main(String[] args) {
        mdlAccount acct = new mdlAccount( "GumB", 100.0 );
        System.out.println("Initial balance is " + acct.getBalance());
        acct.deposit( 50.0 );
        System.out.println("Current balance is " + acct.getBalance());

  • [Need help with a swf file]

    Hello,
    I need help with a flash demo that I am creating. I have a
    main swf file that contains links to other sub swfs that I have
    created. What I really want this to do is... when I click on one of
    the link on the browser, the other swf have to load in the window.
    I tried to code it with .loadMovie,.... but for some weird reason,
    it is not showing up.
    Can anyone help me on this?
    Thanks

    you might have a security violation and you do have a
    load-target issue. remove that "_parent": there's no 2nd parameter
    in the loadMovie() method.
    if you want to replace the main swf with that url, loading
    into _root is fine. otherwise, you want to use a different
    target.

  • Help with splitting a file

    I'm Starting in Java programing and need some help.
    Based in the information of txt file, I need to split a file.txt into "n" .txt files, depending of the blocks thats the file containt. It's delimited by """".
    And put the name between "UZ0RN0" the second field
    Example:
    "01APR02","UZ0RN0","******************************************
    EMHA PNR.UZ0RN0 CR01APR 0419Z MEX BY GS BT
    MEX GS BT 01APR 0421Z 385310 MX
    "01APR02","TSCS44","******************************************
    etc.
    My question is how do I split a file into parts eg split test.txt into UZ0RN0.txt, TSCS44.txt, etc.
    Pls help. Where do I start? I just need help with the the manage of the java.nio.channels.FileChannel to generate several files
    Thanks a lot.

    Ok Thats is the final code:
    This program divide a file.txt in "n" files.txt's according of the block's that the file.txt contain and catch the name of the second tokent to name the new file.txt
    import java.io.*;
    import java.nio.*;
    import java.nio.ByteBuffer;
    import java.nio.channels.FileChannel;
    public class FileCopy {
         public static void main(String[] args) {
              if(args.length==0) {
                   System.out.println("No existe archivo a copiar. Application usage is: \n" +
                                            "java -classpath. Filecopy \" filepath\"" );
                   System.exit(1);
              File fromFile = new File(args[0]);
              if(!fromFile.exists()) {
                   System.out.println("Archivo a copiar. " + fromFile.getAbsolutePath()
                                       + ", no existe.");
                   System.exit(1);
              FileInputStream inFile = null;
              try{
                   inFile = new FileInputStream(fromFile);
              } catch(FileNotFoundException e) {
                   e.printStackTrace(System.err);
                   //assert false;
              FileChannel inChannel = inFile.getChannel();
              try{
              int SizeFile = (int)inChannel.size();
              ByteBuffer buf = ByteBuffer.allocate(SizeFile);
              int length = 0;
              int lengthArch = 0;
              int NoArch = 0;
              int NoComilla = 0;
              String str = new String("");
              try{
                   while ((length = inChannel.read(buf)) != -1 ) {
                        buf.rewind();
                        for (int i=0; i<length; i++) {
                        lengthArch++;
                        byte b = buf.get();
                        //Delimita caracter. Cada bloque tiene 6 "'s
                        if ( b == 34 ) {
                             NoArch++;
                             NoComilla++;
                        //Definir nombre del archivo
                        if (NoComilla==3) {
                             if ( b!=34) {
                             str += (char)b;
                        //Imprime archivo
                        if (NoComilla==6) {
                             fromFile = fromFile.getAbsoluteFile();                         //Asegura una ruta absoluta
                             File parentDir = new File(fromFile.getParent());          //Obtiene el directorio
                             File bFile = new File(parentDir,str + ".txt");               //Genera nuevo archivo
                             str = ("");
                             File toFile1 = createFile(bFile);
                             FileOutputStream outFile1 = null;
                             try{
                                  outFile1 = new FileOutputStream(toFile1);
                             } catch(FileNotFoundException e) {
                                  e.printStackTrace(System.err);
                                  //assert false;
                             FileChannel outChannel1 = outFile1.getChannel();
                             // Write the files
                             try {
                             inChannel.transferTo(((i + 1) - lengthArch),lengthArch,outChannel1);
                             outFile1.close(); // Close the output stream & the channel
                             System.out.println("Archivo " + (NoArch/6) +": " + ((i +1) - lengthArch) + " long " + lengthArch);
                             } catch(IOException e) {
                                  e.printStackTrace(System.err);
                                  System.exit(1);
                             lengthArch = 0;
                             NoComilla = 0;
                        //System.out.print((char)b);
                   buf.clear();
              System.out.println("Tamano del archivo de Origen " + SizeFile);
              System.out.println("EOF " + (NoArch/6) + " Archivos copiados.");
              catch(IOException e) {
                   e.printStackTrace(System.err);
                   System.exit(1);
              inFile.close();
              } catch(IOException e) {
                   e.printStackTrace(System.err);
                   System.exit(1);
              System.exit(0);
         // Metodo para crear un achivo y en caso de que exista hacer *+_backup.*
         public static File createFile(File aFile) {
              aFile = aFile.getAbsoluteFile();                         //Asegura una ruta absoluta
              File parentDir = new File(aFile.getParent());          //Obtiene el directorio
              String name = aFile.getName();                              //Obtiene el nombre del archivo
              int period = name.indexOf('.');                              //Busca el separador de la extension
              if(period == -1)                                             //Si no es
                   period = name.length();                                   //Lo coloca al final del String
              String nameAdd = "_backup";                                   //Agrega "Backup" al nombre
              //Crea el objeto archivo que es unico
              File backup = new File(name.substring(0,period)
                                       + name.substring(period));
              while (backup.exists()) {                                   //Si el nombre ya existe....
                   name = backup.getName();                              //Obtiene el nombre actual del archivo
                   period += nameAdd.length();                              //Agrega el separador
                   backup = new File(parentDir, name.substring(0,period) //agrega backup de nuevo
                                       + nameAdd + name.substring(period));
              return backup;
    This is the example of the file with 2 blocks
    "01APR02","UZ0RN0","******************************************
    EMHA PNR.UZ0RN0 CR01APR 0419Z MEX BY GS BT
    385310 MX
    ***1.ALCANTARA/JORGEALBERTO
    FONE-MEX/N000
    RCVD-PAX
    TKT -T/OK
    1 MX 7M 01APR MEXMTY HK 1 650A 815A
    AB * FLT 7 7A
    RCVD-PAX
    MEX GS BT 01APR 0419Z 385310 MX
    AB | FLT 7 7A
    RCVD-PAX
    MEX GS BT 01APR 0421Z 385310 MX
    "01APR02","TSCS44","******************************************
    .... PNR.TSCS44 CR25MAR 1834Z HDQ BY RM 1S
    ***1.1BRAVO/OCTAVIO
    FONE-MTY1-81503300*A/A528
    RLOC-HDQ1SJOXMWV/D4C2/86511574/MTY/1S/T/MX
    /MXN
    G FX-OSI YY 86511574 / VILLATOURS CENTRO P
    CC D4C2
    OSI MX TKNA 13235822315830
    SSRSEATMXHS1MTYMEX0070K28MAR.16B
    SSRSEATMXHS1MEXMTY0007K01APR.09B
    1 MX 70K 28MAR MTYMEX HK 1 645A 815A
    2 MX 7K 01APR MEXMTY HK 1 650A 815A
    X3 SSRSEATMXNN1MTYMEX0070K28MAR.16B
    RCVD-
    HDQ RM 1S 25MAR 2205Z
    X3 SSRSEATMXNN1MEXMTY0007K01APR.09B
    RCVD-
    HDQ RM 1S 25MAR 2231Z
    X3 SSRSEATMXKK1MTYMEX0070K28MAR.16BN
    X3 SSRSEATMXKK1MEXMTY0007K01APR.09BN
    RCHDQ1SJOXMWV/D4C2/86511574/MTY/1S/T/MX
    /MXN
    HDQ RM 1S 26MAR 0055Z
    Chao/Bye

  • Need help with .cr2 RAW-files

    Hi,
    I've installed Aperture 2.1.2, and the newest RAW compability update (2.5).
    However, when I try to work with RAW files from my Canon EOS 1000D camera (nothing big, I know), all I see is "Unsupported image format".
    I really need help with this quick. The RAW files are in .cr2 format.

    as a last resort ...
    this is the update that added support for 1000d ... however the 3 releases post this should have it too ...
    http://www.apple.com/downloads/macosx/apple/application_updates/digitalcameraraw compatibilityupdate22.html
    but you can roll back your raw compatibility and see if that works ... then progressively go forward to current and see if/where the problem lies ...
    you could try a re-install of 2.5 ...
    http://support.apple.com/downloads/DigitalCamera_RAW_Compatibility_Update_25
    info on rolling back the update is in this thread:
    http://discussions.apple.com/thread.jspa?messageID=9097867

  • Begging for help with podcast xml file

    Hey All,
    I have a podcast on iTunes.  I am hosting the xml file and podcast mp3s on a friends server so Im not using any service.  Everything is working and Ive sucessfully added 4 podcasts so far, and it shows up correctly in iTunes on my PC.
    However my podcasts do not showup correct in the iTunes store website, or on idevices.  Meaning, I number my shows 001_"NAME" 002_"NAME" etc.  Yet in the iTunes store they show up out of order.  So my last show is not at the top its at the bottom, and they are all mixed up (like 002, 001, 004, 003 instead of  4,3,2,1)  Also the publish date is the same on two of them (and not what i have in the xml file) and doesnt show up at all on the other two.  I assume this is a problem with the xml file, yet I dont see any problems with it.  But it seems odd that it all works correctly in the actual iTunes program.  Ive tried different code, but im very much a noob at it, and everything i find online is from 5 - 10 years ago or wants you to host your podcasts with their site and I dont need that. 
    Here is the link to the show on the iTunes website so you can see what i mean:  http://itunes.apple.com/us/podcast/your-reality-recap/id501295325
    If anybody can, would you mind checking out the code in my xml file and letting me know if you see anything thats causing this issue?
    I zipped the xml file and put it here:  http://www.ericcurto.com/podcast/YRR.zip
    I would be truly greatfuly for any help with this.  Ive been trying to fix this for days and dont know what else to do. 
    Thanks!
    Eric

    Your feed is at http://www.ericcurto.com/podcast/YourRealityRecap.xml (please always post the feed URL, not its contents or a copy).
    I don't see the issues you mention. The order in the Store and when subscribing is what I would expect:
    The order in the Store depends on clicking the header to the column: the default is the first one. Some of the dates are a day out - this is quite commmon and is probably a time zone issue (it may be different where you are - I'm in the UK). I don't know why you are seeing a garbled order unless you've clicked on one of the other columns in the Store.

  • Help with building flash files for streaming

    I filmed a product demonstration for a client who wanted to put it on his website.  I edited the footage in PremPro CS4 and exported to Media Encoder as F4V file format.  After encoding imported footage into CS4 Encore, created timeline, chose, Flash from Format and swf for output.  Progressive Download which allows video to begin playing as it is downloaded (I believe), chose destinations and settings.  After transcoding I had 1 file folder, Sources that contained the following files _PGC_Bpge_entryPoint_Bbp_1.f4v, and then 3 separate files, *not* in the file folder called Sources.  They are
    AuthoredContent.xml, FlashDVD.swf, and Index.html.
    I submitted all files to client who gave them to web designer.  Designer said these were the wrong files and he could not use them. I called designer and basically he said I didn't know what I was doing.  I told him he needed all files to put up the flash video.  Anyway, am I missing something, doing something wrong?  Are there other files he needs?  He said he only needed 1 file.  Or is it the designer?  I'm not thin skinned so if it's me please tell me so, so I don't make the same errors.  Thanks.  All suggestions/comments are appreciated!

    <The client wants a control player, i.e. play, stop, pause, etc., that's it, so the viewer can simply provide the function themselves.  This is similar to youtube, blogger, etc.
    The web designer can use what you provided, which does what you describe the client wanting.  But the web designer may need to integrate what Encore provided onto a web page, and the client may not have made the expectations clear and may not know what is needed.  As I said, the Encore to flash player gives almost no options for the player controls and colors etc may be problems.
    <Encore did encode the f4v file.  When I exported from PremPro what preset should I hve chosen -- mpeg2 DVD, flv/f4v.  So the only file he needs in addition to what I gave him is the original f4v file?
    I don't know whether the f4v you exported from Premiere was progressive.  The f4v from Encore might be fine, or you might need to export from Premiere again.
    The other issue is that some "player" with controls needs to be provided by you or the web designer (who may have an issue with the client not getting the designer to lay all this out to begin with).  There are several threads about "flv players" you might check out.  Does the client have video on his site already?  If so, you can figure out what they are using, and it will help with your process.
    should I have chosen "flash server" instead of "progressive".  i must admit i never did this before.  other clients just have me post it to youtube and provide them with embed code.
    It depends on what they want.

  • Help with backing up files and opening from disk image.

    I am trying to back up my hard drive so that I can send my PowerBook in for repair. I used disk utility from my Panther install discs to create a disk image of my HD.
    The disk image was created successfully and mounts perfectly on my HD. I can open it and open all of my files from the disk image just fine when it is mounted on my PowerBook.
    However, when I take it to a different Mac, things start getting sketchy. I can open Word files just fine, but Excel files claim they are read-only and cannot open. I checked the permission back on my PowerBook to see what was up, and the files were read/write for the owner and read-only for groups and others, but they should still open as read-only files right? I even checked the permissions on the Word files to see if there was a difference, but there was no difference.
    I can take the external HD back to my PowerBook, remount it, and open everything fine, but then on the other Mac it is a no go.
    I need to back this up for when it is out on repair, but I need to know that the files will open in case I need to restore my disk.
    Can anyone help??
    BTW, I couldn't find the best forum to post this in, if there is a better one please direct me there...

    solution:
    I went into the Apple Store nearby today to send my PowerBook off for repair for a screen issue, and in the process got help with my backing up issue.
    It seems all one needs to do is copy the file from the external hard drive to the internal drive.
    It was that simple.
    Jason

  • Help with transferring music files from my Maxtor external HD

    Can anyone please help? I have been using Windows based PCs for a majority of my life. I recently purchased a Macbook. I have thousands of songs saved on a Maxtor external hard drive. I recently connected the HD to my Macbook and was able to successfully copy over all of the photos I have saved and only few of the audio files. I checked the audio files are saved in itunes format. Why can I not copy all of my music over? Please help!

    You could try something like this, if you haven't thought of it already. On the PC side make a new folder, probably at the top level, or perhaps next to the one folder that you could see on the Mac side. Or maybe inside the one folder you can see on the Mac side. Maybe create a new file in it, such as a simple text file. Then see if the new folder and file can be seen on the Mac side. If so, go back to the PC side and try copying one of the mp3 files that couldn't be seen into that new folder. Also, move one mp3, as distinct from copying. Back to the Mac side, see if you can see them.
    Now, if you could see the new text file, but can't see the copied mp3, that implies the problem is somehow with the mp3 files. Or the folders they are in.
    If you couldn't see the new folder, then the problem isn't the files, but (I guess) something obscure and arcane about the filesystem.
    Hopefully, the new folder and its contents will be visible on the Mac side, in which case the path forward should be clear.
    Do you have an extremely large number of song files in a single folder? Grasping at straws, but maybe the Mac has some dumb limit that's smaller than the equivalent limit on the PC side. I've never heard of such a thing, but when things are weird, it's a good time to think of oddball possibilities...

Maybe you are looking for