- #Stata package text scanner install
- #Stata package text scanner software
- #Stata package text scanner code
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,įITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
#Stata package text scanner software
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR The above copyright notice and this permission notice shall be included in allĬopies or substantial portions of the Software. To use, copy, modify, merge, publish, distribute, sublicense, and/or sellĬopies of the Software, and to permit persons to whom the Software isįurnished to do so, subject to the following conditions: In the Software without restriction, including without limitation the rights Of this software and associated documentation files (the "Software"), to deal Permission is hereby granted, free of charge, to any person obtaining a copy List of all found pip libraries in your project, result from n(). Writes the output to the console or a path specified in the constructor Runs the scan, output will be stored in libraries_found Output path to write the resutlts from output() to
#Stata package text scanner install
library(ABC) Load the package -ABC- to your workspace Install the following packages: install. A window will pop-up, select a mirror site to download from (the closest to where you are) and click ok. libraries_found # Isn't it beautiful? Class definitions pip_module_(]) Methodĭirectory to recursively scan through, defaults to current working directory. Installing/loading packages/userwritten programs install.packages('ABC') This will install the package -ABC. version )) except ScannerException as e : print ( "Error: %s " % str ( e ))įor the one-liner junkies out there (like me) you can also get all libraries with this nifty little one-liner (I'm so considerate) from pip_module_scanner.scanner import Scanner libs = Scanner (). libraries_found : print ( "Found module %s at version %s " % ( lib. run () # do whatever you want with the results here # example: for lib in scanner. Specifying a path would work like so, make sure to also import the ScannerException as it will check if the path you specified is actually a real path: from pip_module_scanner.scanner import Scanner, ScannerException try : scanner = Scanner ( path = "~/projects/my-awesome-project/" ) scanner. To do this, you can use it like so: from pip_module_scanner.scanner import Scanner scanner = Scanner () scanner.
#Stata package text scanner code
You can easily integrate the scanner code in your own project so you can get the output of the scanner yourself or modify the class to suit your own needs. Example: $ cd ~/projects/my-awesome-project/ You can write the output of the script to a file by using the -o or -out argument. Example: $ pip-module-scanner -path ~/projects/my-awesome-project/ You can specify a custom path in which you want to run the script with the -p or -path argument. Open a terminal and navigate to your project folder, run the script and watch magic happen before your eyes. Installing the scanner is easy, either clone the repository and run the script or install it via pip like so: $ pip install pip-module-scanner Scans your Python project for all installed third party pip libraries that are used and generates a requirements.txt based output.