Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

slowpeek/mc-squashfs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Deprecation notice

This repo is no longer updated. It has been merged into https://github.com/slowpeek/mc-extfs-sp

About

This is a SquashFS plugin for Midnight Commander. Having it installed, you could explore the content of your *.squashfs and *.sqfs files the same way you do with zip, 7z etc.

Notice: When you access some file via a vfs layer in mc, the file is extracted into a temp dir (in order of precedence: $MC_TMPDIR, $TMPDIR, /tmp). So, for example, it is not a very bright idea to browse into a big squashfs file inside some ISO image: the whole squash would be extracted into the temp dir.

Installation

The code is based on the unsquashfs tool. In Ubuntu it comes with squashfs-tools package.

Notice: Pathes used below are from Ubuntu. It might differ in your distro.

There are two relevant config files:

  • global /etc/mc/mc.ext (since 4.8.29: /etc/mc/mc.ext.ini)
  • local ~/.config/mc/mc.ext (since 4.8.29: ~/.config/mc/mc.ext.ini).

The global config is not loaded if the local one exists.

Config snippet for this script (check your mc version with F1 key):

till 4.8.28
# .squashfs, .sqfs
regex/\.(squashfs|sqfs)
    Open=%cd %p/usqfs://
    
4.8.29+
[squashfs]
Regex=\.(squashfs|sqfs)$
Open=%cd %p/usqfs://
    

Local

  • extract the archive or clone the repo somewhere
  • point ~/.local/share/mc/extfs.d/usqfs symlink to the script
  • in mc menu select Command, then Edit extension file
  • insert the snippet somewhere under ### Archives ###
  • save it and exit the editor
  • restart mc to apply the changes

Global

  • extract the archive or clone the repo somewhere
  • point ~/usr/lib/mc/extfs.d/usqfs symlink to the script
  • open /etc/mc/mc.ext (since 4.8.29: /etc/mc/mc.ext.ini) in some editor
  • insert the snippet somewhere under ### Archives ###
  • save it and exit the editor
  • restart mc to apply the changes

Releases

No releases published

Packages

No packages published