johnhc

How to expand .in_ file?

23 posts in this topic

I think I used to use the expand command to get the .sys file from the .sy_ file. Today I cannot get it to work without specifying the output file name. So how do I expand an .in_ file? Is it a .inf or a .ini file? I know 7-zip works just fine but how does W7 do it? Thanks and enjoy, John.

0

Share this post


Link to post
Share on other sites

I use this...

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\Expand]
"extended"=""

[HKEY_CLASSES_ROOT\*\shell\Expand\command]
@="expand -r \"%1\""

This...

[HKEY_CLASSES_ROOT\*\shell\Expand]

"extended"=""

Makes it so that you have to press shift for the menu item to appear. You can leave it out but then your context menu gets kinda crowded.

To do the reverse....

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\Makecab]
"extended"=""

[HKEY_CLASSES_ROOT\*\shell\Makecab\command]
@="makecab \"%1\""

0

Share this post


Link to post
Share on other sites

Broken google? :w00t:

See:

http://www.computerhope.com/expandhl.htm

The -r switch should work allright, and the -d will give you the info, example (XP):

expand -d usb.in_
Utilit… di espansione file Microsoft (R) Versione 5.1.2600.0
Copyright (C) Microsoft Corp 1990-1999. Tutti i diritti riservati.

usb.in_: usb.inf

jaclaz

0

Share this post


Link to post
Share on other sites

I made Vb.Net app that Expands abd Compresses files using MakeCab,

just drag and drop the file on to the app.. You could also put this into the

SendTo Folder to have it work from there.

MakeCabAndExpand

0

Share this post


Link to post
Share on other sites

Thanks, all. All good information. jaclaz, I doubt Google is broken. I found many pages with information and used MS Technet/MSDN. I saw the -r switch but did not understand that it would do what I wanted and do not remember using it in XP. Why does the command description not say "Rename output file to original name"? Also the command description says the -r switch is only valid when the file is compressed with the -r switch. I assumed (erroneously) that it wanted a name (supplied my me) and that was what I was trying to avoid. Most of the pages specifically said to rename the output file in the command line. I assume when Windows expands files (such as drivers) this is the method used. Thanks much and enjoy, John.

0

Share this post


Link to post
Share on other sites

Methinks you misunderstand -

COMPRESS [-r] [-d] [-z] Source Destination

COMPRESS -r [-d] [-z] Source [Destination]

-r Rename compressed files.

The link doesn't explicitly say that but...

edit - found in various Resource Kits (as well as old DOS).

Article with link to 2K3 RK...

Edited by submix8c
0

Share this post


Link to post
Share on other sites

Different versions have different syntax. The one you most likely have is in WinXP normally in the \i386 folder and has this /? help ...

C:\WinXP_CDROM\I386>expand /?

Microsoft ® File Expansion Utility Version 5.1.2600.0

Copyright © Microsoft Corp 1990-1999. All rights reserved.

Expands one or more compressed files.

EXPAND [-r] Source Destination

EXPAND -r Source [Destination]

EXPAND -D Source.cab [-F:Files]

EXPAND Source.cab -F:Files Destination

-r .......... Rename expanded files.

-D .......... Display list of files in source.

Source ...... Source file specification. Wildcards may be used.

-F:Files .... Name of files to expand from a .CAB.

Destination . Destination file | path specification.

............. Destination may be a directory.

............. If Source is multiple files and -r is not specified,

............. Destination must be a directory.

As well as using the command line, there are a few other ways to accomplish this.

For example, if you happen to have WinRar, you can just drop them into an open WinRar window to see what's 'inside' and 'extract' ( expand ) it if you wish.

You can create a context menu EXPAND item as X described.

My current favorite alternative is assigning all those compressed cabinet extensions to something like WinRar. Unfortunately there is no wildcard allowed ( e.g., .??_ or .*_ ) so each individual extension would need to be associated with the main class. At last count I had 114 extensions.

My current list of compressed cabinet archive extensions ...

[HKEY_LOCAL_MACHINE\Software\Classes\._]

[HKEY_LOCAL_MACHINE\Software\Classes\.ac_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ad_]

[HKEY_LOCAL_MACHINE\Software\Classes\.an_]

[HKEY_LOCAL_MACHINE\Software\Classes\.as_]

[HKEY_LOCAL_MACHINE\Software\Classes\.av_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ax_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ba_]

[HKEY_LOCAL_MACHINE\Software\Classes\.bi_]

[HKEY_LOCAL_MACHINE\Software\Classes\.bm_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ca_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ch_]

[HKEY_LOCAL_MACHINE\Software\Classes\.cm_]

[HKEY_LOCAL_MACHINE\Software\Classes\.cn_]

[HKEY_LOCAL_MACHINE\Software\Classes\.co_]

[HKEY_LOCAL_MACHINE\Software\Classes\.cp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.cs_]

[HKEY_LOCAL_MACHINE\Software\Classes\.cu_]

[HKEY_LOCAL_MACHINE\Software\Classes\.da_]

[HKEY_LOCAL_MACHINE\Software\Classes\.db_]

[HKEY_LOCAL_MACHINE\Software\Classes\.de_]

[HKEY_LOCAL_MACHINE\Software\Classes\.di_]

[HKEY_LOCAL_MACHINE\Software\Classes\.dl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.do_]

[HKEY_LOCAL_MACHINE\Software\Classes\.dr_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ds_]

[HKEY_LOCAL_MACHINE\Software\Classes\.dt_]

[HKEY_LOCAL_MACHINE\Software\Classes\.du_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ec_]

[HKEY_LOCAL_MACHINE\Software\Classes\.en_]

[HKEY_LOCAL_MACHINE\Software\Classes\.es_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ex_]

[HKEY_LOCAL_MACHINE\Software\Classes\.fo_]

[HKEY_LOCAL_MACHINE\Software\Classes\.fr_]

[HKEY_LOCAL_MACHINE\Software\Classes\.gi_]

[HKEY_LOCAL_MACHINE\Software\Classes\.gp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.gr_]

[HKEY_LOCAL_MACHINE\Software\Classes\.h2_]

[HKEY_LOCAL_MACHINE\Software\Classes\.h_]

[HKEY_LOCAL_MACHINE\Software\Classes\.hl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ht_]

[HKEY_LOCAL_MACHINE\Software\Classes\.hx_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ic_]

[HKEY_LOCAL_MACHINE\Software\Classes\.im_]

[HKEY_LOCAL_MACHINE\Software\Classes\.in_]

[HKEY_LOCAL_MACHINE\Software\Classes\.is_]

[HKEY_LOCAL_MACHINE\Software\Classes\.it_]

[HKEY_LOCAL_MACHINE\Software\Classes\.jc_]

[HKEY_LOCAL_MACHINE\Software\Classes\.jp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.js_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ko_]

[HKEY_LOCAL_MACHINE\Software\Classes\.le_]

[HKEY_LOCAL_MACHINE\Software\Classes\.lx_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ma_]

[HKEY_LOCAL_MACHINE\Software\Classes\.mb_]

[HKEY_LOCAL_MACHINE\Software\Classes\.md_]

[HKEY_LOCAL_MACHINE\Software\Classes\.mf_]

[HKEY_LOCAL_MACHINE\Software\Classes\.mi_]

[HKEY_LOCAL_MACHINE\Software\Classes\.mm_]

[HKEY_LOCAL_MACHINE\Software\Classes\.mo_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ms_]

[HKEY_LOCAL_MACHINE\Software\Classes\.n1_]

[HKEY_LOCAL_MACHINE\Software\Classes\.nl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.nt_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ob_]

[HKEY_LOCAL_MACHINE\Software\Classes\.oc_]

[HKEY_LOCAL_MACHINE\Software\Classes\.os_]

[HKEY_LOCAL_MACHINE\Software\Classes\.pi_]

[HKEY_LOCAL_MACHINE\Software\Classes\.pl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.pm_]

[HKEY_LOCAL_MACHINE\Software\Classes\.pn_]

[HKEY_LOCAL_MACHINE\Software\Classes\.pp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.pr_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ra_]

[HKEY_LOCAL_MACHINE\Software\Classes\.re_]

[HKEY_LOCAL_MACHINE\Software\Classes\.rl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ro_]

[HKEY_LOCAL_MACHINE\Software\Classes\.rs_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sa_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sc_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sd_]

[HKEY_LOCAL_MACHINE\Software\Classes\.se_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sh_]

[HKEY_LOCAL_MACHINE\Software\Classes\.si_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sq_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sr_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sv_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sw_]

[HKEY_LOCAL_MACHINE\Software\Classes\.sy_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ta_]

[HKEY_LOCAL_MACHINE\Software\Classes\.tb_]

[HKEY_LOCAL_MACHINE\Software\Classes\.th_]

[HKEY_LOCAL_MACHINE\Software\Classes\.tl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.tp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.tr_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ts_]

[HKEY_LOCAL_MACHINE\Software\Classes\.tt_]

[HKEY_LOCAL_MACHINE\Software\Classes\.tx_]

[HKEY_LOCAL_MACHINE\Software\Classes\.uc_]

[HKEY_LOCAL_MACHINE\Software\Classes\.vb_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ve_]

[HKEY_LOCAL_MACHINE\Software\Classes\.vx_]

[HKEY_LOCAL_MACHINE\Software\Classes\.wa_]

[HKEY_LOCAL_MACHINE\Software\Classes\.wb_]

[HKEY_LOCAL_MACHINE\Software\Classes\.we_]

[HKEY_LOCAL_MACHINE\Software\Classes\.wk_]

[HKEY_LOCAL_MACHINE\Software\Classes\.wm_]

[HKEY_LOCAL_MACHINE\Software\Classes\.wp_]

[HKEY_LOCAL_MACHINE\Software\Classes\.ws_]

[HKEY_LOCAL_MACHINE\Software\Classes\.xl_]

[HKEY_LOCAL_MACHINE\Software\Classes\.xm_]

[HKEY_LOCAL_MACHINE\Software\Classes\.xs_]

[HKEY_LOCAL_MACHINE\Software\Classes\.zi_]

Anyway, I created a new main class called: [HKEY_LOCAL_MACHINE\Software\Classes\_MsCab] with all the subkeys needed to execute WinRar when one of those extensions are opened. So if you doubleclick one, like I mentioned above it opens in a WinRar window like a ZIP or RAR might ( obviously an illusion since they are not archives ). But it is good because I get to see the original file name/date/time/size in the WinRar window and then decide whether to 'extract' ( actually 'expand' ) the file or not. Never did get the dragdrop handler working though. :angry: That is the gold ring I think, being able to dragdrop and expand multiple files. Another benefit is that since they are associated, in a file manager window they get assigned a proper icon and description.

Obligatory Rant: Microsoft COMPRESS/EXPAND has been a royal PITA since, well, almost forever. Many different incompatible versions, differing syntax and only a few with identifiable signatures to determine which one can be used to decompress a given file. So it was almost always trial and error to get them expanded ( not with WinXP as in your case, but in previous years ). The dumbest idea ever was an /i386 folder with almost 6,000 compressed *.*_ files in a single directory. Yes, some minor amount of disk space is saved in total for larger files but it is eaten away by the numerous files with slack that were originally below or compressed below the minimum file size using 4KB clusters ( yeah I know NTFS has an MFT exception for really small files but that is only ~700 of the 6,000 ) . For some reason they simply refused to incorporate a monolithic archive strategy, that is until much later when they came to their senses and used the WIM idea which they could have done all along with ARC or ZIP or RAR or others.

EDIT: arrghh! I thought this was in the WinXP forum. Strike those "WinXP" references. :lol:

Edited by CharlotteTheHarlot
0

Share this post


Link to post
Share on other sites

Well, I was replying (mainly) to this question:

Is it a .inf or a .ini file?

The part that IMHO is not clear at all in the syntax is that the -d switch will normally work also for "single" files (and not "only" for "multifile" .cab or whatever).

jaclaz

0

Share this post


Link to post
Share on other sites

Thanks again, all. I am not sure what I misunderstood except how the -r switch works on the Expand command. My system (W7 x64) does not have a COMPRESS command. What I was trying to understand was how Windows expands driver files of the form .xx_. I ran into a problem with the Catalyst video driver files using some compression technique that Windows did not understand and I could not inject the driver into W7 install image. Thanks for all the suggestions and references - all good. Enjoy, John.

0

Share this post


Link to post
Share on other sites
Is it a .inf or a .ini file?

johnhc,

What is the source of this file? Is it of recent vintage? If it is, it will likely be using the cabinet format since about WinXP, and the original filename will be encoded.

Do you have WinRar installed? If you do, all you have to do is open WinRar and then drag and drop the xyz.in_ into the GUI. The GUI then changes to the 'contents' of this xyz.in_ file, and if it is a recent MsCab you will see the real filename and other details. From here you can extract it also. NB: this file is not an archive, it just looks that way. Don't try to add files to it!

Examples from WinXP(sp3) found in the \i386 folder dropped into a WinRar window ...

-- Information on Disk --- Information shown when dropped into WinRar GUI

FILENAME ........ SIZE --- FILENAME ........ SIZE .... PACKED .... DATE

Adcjavas.in_ ..... 387 --- adcjavas.inc ..... 629 ...... ? .... 2008-04-13

Adm_Mult.in_ ..... 879 --- adm_mult.inf ... 2,620 ...... ? .... 2001-08-17

System.in_ ....... 319 --- system.ini ....... 219 ...... ? .... 2001-07-21

Perhaps you have 7-zip instead. It can do much the same. However there are quirky differences in it's GUI compared to WinRar. Forget about drag/drop into 7-zip ( unless there is some setting I missed ). You can however just open the GUI and go to the folder with the files and right-click one and select 'Open Inside'. Now you will see the same information with one difference, it will show the packing method.

-- Information on Disk --- Information shown by 'Open Inside' the 7-zip GUI

FILENAME ........ SIZE --- FILENAME ........ SIZE ... METHOD ..... DATE

Adcjavas.in_ ..... 387 --- adcjavas.inc ..... 629 ... LZX:21 .. 2008-04-13

Adm_Mult.in_ ..... 879 --- adm_mult.inf ... 2,620 ... LZX:21 .. 2001-08-17

System.in_ ....... 319 --- system.ini ....... 219 ... LZX:21 .. 2001-07-21

NB: In 7-zip don't double-click the file or right-click it and select 'Open' even though they are functionally equivalent at this step. IMHO you should never execute a file 'inside' an archive because generally that means to extract it to temp and then run it according to system file associations. This is a dangerous practice. 7-zip GUI seems to have 'Open' ( execute outside ) rather than 'Open Inside' ( view inside ) as the default for double-click in most circumstances so I play it safe and then right-click and select the 'Open Inside' choice.

EDIT: clarity, typos

Edited by CharlotteTheHarlot
0

Share this post


Link to post
Share on other sites

"COMPRESS.EXE" doesn't exist (AFAIK) on any OS by Default. You need to get the Resource Kit Tools. A search reveals that the latest one is from the Server 2K3 (link I gave). I might (wrongly) assume that it may work on Win7/2K8 x86/x64. However, I found this which indicates the Tools do indeed work.

Catalyst Drivers Packages are InstallShield "packed" with NSIS AFAIK. Different beast. Yours?

Here is an interesting notation by Trip on "including" an EXE (undoubtedly how the Drivers are downloaded).

edit - You can use Universal Extractor to "unpack" it, then you have to use it AGAIN to get the DATA1.CAB unpacked (provided the NEWEST InstallShield wasn't used) inside the Driver folder AND use the appropriate INF's from (maybe) a DIFFERENT folder. This is ONLY the Drivers and NOT the CCC... At least this is how it's done with an OLDER version of Catalyst (+CCC).

From AMD link above -

Package contains...

Display Driver

OpenCL Driver

AMD Integrated Driver

Catalyst Control Center

"Combo" Packages... Edited by submix8c
0

Share this post


Link to post
Share on other sites

The Catalyst drivers are different! You should have said that you want to unpack them in the very beginning of the topic!

I've got no time now to explain more but there are several packed files there, like *.*_ and if you unpack them using "expand -r" they will still unpack to *.*_ !!! After unpacking you need to rename them manually, ex. .dl_ should become .dll, etc..

0

Share this post


Link to post
Share on other sites

I asked a simple question:

I know 7-zip works just fine but how does W7 do it?
I solved the Catalyst problem (not injectable via DISM) some time ago with a small script file (roots found on MSFN) and an important hint from a thread on the AMD forum. The hint was that 7-zip (v9.20) would extract the .xx_ files in the Catalyst drivers. My small script used 7-zip to extract all files and makecab to compress them again. Injection works fine and driver works fine. When I processed a new driver, 12.8, I was surprised that my output files when extracted by expand command still had the .xx_ name. Thus my post. I still suspect that XP expand does not need the -r switch and thus my error. Now it seems the latest Catalyst drivers no longer use the strange compression and they inject without my running the script against them - still trying to figure out how to test them. Thanks to all. I learned a lot and this is always good. Enjoy, John.
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.