Skip to main content

Built with Spacemacs Instagram Twitter Facebook


MIT license forthebadge made-with-python


LSG => ls | grep

Table of contents

Introduction

This project started as a shell script for ls | grep to check if a folder contains the file which I am looking for.

I tried using find and other unix-like tools, but either they were too complicated to use or the results were not what I wanted.

The package doesn't aim to revolutionize the way you do your ls or anything else. Its just a better substitution to bash script.

Back to top

Features

  • Search for multiple files and folders.
  • Specify a path to search or it will search within current directory.
  • Print total number of results.
  • Case insensitive substring search.
  • Results are displayed in separate categories.
  • OS agnostic

Back to top

Getting Started

Installation

pip install lsg

Usage

lsg FILENAME

  • Search for .py files in current directory.

    $ lsg .py
    ----------Total number of entries----------> 1
    ----------Files----------------------------> 1
    setup.py
    
  • Search for .py files in lsg directory.

    $ lsg .py -p lsg
    ----------Total number of entries----------> 2
    ----------Files----------------------------> 2
    __init__.py
    main.py
    

Back to top

Full Documentation

For more help run lsg -h or lsg --help on terminal.

$ lsg -h
usage: lsg [-h] [--path PATH] FILENAME [FILENAME ...]

Check if a specific file or folder exists in current or in a specified
directory

positional arguments:
  FILENAME              name of file or folder to search

optional arguments:
  -h, --help            show this help message and exit
  --path PATH, -p PATH  path to search (default: current directory)

Any feature requests, bugs etc feel free to create an issue on Gitlab.

Read CHANGELOG, CODE OF CONDUCT, CONTRIBUTING guide.

License

MIT License

Copyright (c) 2019 Justine Thomas Kizhakkinedath

Back to top


forthebadge forthebadge forthebadge


Metadata

Release files for lsg 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lsg 0.1.0
File Size Uploaded
lsg-0.1.0.tar.gz 4.7 kB Details

Release files / lsg-0.1.0.tar.gz

Download URL lsg-0.1.0.tar.gz
Size 4.7 kB
Tags Source
SHA-256 checksum
How to use checksums
29947134052fc682dbd55358a071bc76e85f1acd5b7d6f95740678c2eebedabf
BLAKE2b-256 checksum
How to use checksums
86911359a2e48e17e74b06e74e3ef4709cc1b2d6ddb649afbc3f9063bddcf6da
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.5.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.1

Release history Release notifications | RSS feed

This release

0.1.0 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page