recentpopularlog in

kme : modules   44

php - Alternatives to apache_get_modules() to get list of loaded apache modules - Stack Overflow | https://stackoverflow.com/

* phpinfo() will tell you how PHP is installed, especially the Server API row.
* You could parse the config files for Apache to find out which modules are configured.
* You could run something like apache2 -t -D DUMP_MODULES to obtain a list of modules.
apache  webmaster  modules  annoyance  solution 
november 2019 by kme
apache 2.2 - Difference between mod_authn_ldap and mod_authz_ldap - Server Fault | https://serverfault.com/
mod_authz_ldap seems to be a third-party module that *only* does authorization (not authentication)--whatever that means.
apache  apache22  httpd  ldap  modules  webmaster  maybesolution 
november 2019 by kme
python - how to load virtualenv using environmental module file (tcl script)? - Stack Overflow | https://stackoverflow.com/
I don't think the semicolon is "essential" as the poster notes. You can also 'source /path/to/script.sh' and the changes to the environment seem to be preserved.

<code class="language-tcl">if { [ module-info mode load ] } {
puts stdout "/programs/program-env/bin/activate;"
} elseif { [ module-info mode remove ] } {
puts stdout "deactivate;"
}</code>
environmentmodules  modules  modulefile  tcl  solution  sysadmin 
april 2018 by kme
MODULEFILE(4) manual page (Tcl version) | http://modules.sourceforge.net/
For some reason, now that 4.x is out, it doesn't look like you can reach the 3.2.x documentation from the main Environment Modules site anymore.
modules  hpc  sysadmin  modulefile  reference 
november 2017 by kme
Environment Modules / Mailing Lists | https://sourceforge.net/
It cannot be seen on the C version as module aliases are not part of the result of the avail command on this implementation.
environmentmodules  modules  annoyance 
november 2017 by kme
perlmodinstall - perldoc.perl.org | https://perldoc.perl.org/
If you don't see an error message, you have the module. (If you do see an error message, it's still possible you have the module, but that it's not in your path, which you can display with perl -e "print qq(@INC)" .) For the remainder of this document, we'll assume that you really honestly truly lack an installed module, but have found it on the CPAN.
perl  modules  troubleshooting  installation  build  reference  newbie 
october 2017 by kme
The CPAN Frequently Asked Questions - www.cpan.org | http://www.cpan.org/
perldoc perllocal

Also: https://metacpan.org/release/pmtools (`cpanm pmtools`)
From the README:

This is pmtools -- a suite of small programs to help manage modules.
The names are totally preliminary, and in fact, so is the code. We follow
the "keep it small" notion of many tiny tools each doing one thing well,
eschewing giant megatools with millions of options.

pmpath - show the module's full path
pmvers - get a module version number
pmdesc - get a module description
pmall - get all installed modules pmdesc descriptions
pmdirs - print the perl module path, newline separated
plxload - show what files a given program loads at compile time
pmload - show what files a given module loads at compile time
pmexp - show a module's exports
pminst - find what's installed
pmeth - list a class's methods, recursively
pmls - long list the module path
pmcat - cat the module source through your pager
pman - show the module's pod docs
pmfunc - show a function source code from a module
podgrep - grep in pods of a file
pfcat - show pods from perlfunc
podtoc - list table of contents of a podpage
podpath - show full path of pod file
pods - list all standard pods and module pods
sitepods - list only pods in site_perl directories
basepods - list only normal "man-page" style pods
faqpods - list only faq pods
modpods - all module pods, including site_perl ones
stdpods - list standard pods, not site_perl ones
perl  cpan  whereis  module  faq  modules  sysadmin  solution 
october 2017 by kme
ModulePackage - ModulePackage.pdf
Video: https://www.youtube.com/watch?v=0oTh1CXRaQ0
Workshop materials: http://dabeaz.com/modulepackage/
# spam/__init__.py
__all__ = []
def export(defn):
globals()[defn.__name__] = defn
__all__.append(defn.__name__)
return defn
from . import foo
from . import bar
Makes the Python version explicit
% python3 -m pip install package

vs

% pip install package

Rant: I can't count the number of times I've had
to debug someone's Python installation because
they're running some kind of "script", but they
have no idea what Python it's actually attached to.
The -m option avoids this.

Neat `-m` tricks:

% python3 -m zipfile -c spam.zip spam/*.py
% rm -rf spam
% ls
spam.zip
% python3 spam.zip

See also: https://www.python.org/dev/peps/pep-0441/
python  packages  modules  slides  howto  newbie  reference  bestpractices 
december 2016 by kme
How do I include a Perl module that's in a different directory? - Stack Overflow
It's the only one that searches relative to the module directory:

use FindBin; # locate this script
use lib "$FindBin::Bin/.."; # use the parent directory
use yourlib;
perl  library  include  modules  packages  import  dammitbrain  solution 
december 2016 by kme
How do I unload (reload) a Python module? - Stack Overflow [http://stackoverflow.com/]
You can reload a module when it has already been imported by using the reload builtin function in Python 2:

python  interactivemode  repl  devel  modules  tipsandtricks 
july 2016 by kme
hiding directories from environment modules at DuckDuckGo - https://duckduckgo.com/
Solution: just omit the "magic cookie" ('#%Module') line from whichever files Modules things are actual modulefiles. Using Mustache, I just hid this line in an "inverted section" for a junk variable name that wouldn't exist in the environment, so the magic cookie would get substituted back in once processed through a Mustache template processor (e.g., 'mo').
solution  modules  sysadmin  hpc  clustercomputing 
march 2016 by kme
virtualbox - Error: kernel headers not found. (But they are in place) - Ask Ubuntu

The message is misleading.

In my case it was actually missing dkms so before you install the addition run

sudo apt-get install build-essential linux-headers-`uname -r` dkms


Installing 'dkms' fixed the problem. The specific error message was
The headers for the current running kernel were not found. If the following
module compilation fails then this could be the reason.
kernel  build  modules  errormessage  solution 
september 2015 by kme
How do I find out what Python libraries are installed on my Mac? - Stack Overflow


For the web server, you can run the pydoc module that is included in the python distribution as a script:

python /path/to/pydoc.py -p 1234

where 1234 is the port you want the server to run at. You can then visit http://localhost:1234/ and browse the documentation.

From the Python REPL (the command-line interpreter / Read-Eval-Print-Loop), type help("modules") to see a list of all your available libs.

Then to see functions within a module, do help("posix"), for example. If you haven't imported the library yet, you have to put quotes around the library's name.
python  modules  libraries  dammitbrain  query  packagemanagement  solution 
july 2015 by kme
Practical mod_perl: 3.9.2.1. Modifying @INC
use lib qw(/home/stas/lib/perl5/5.6.1/
/home/stas/lib/perl5/site_perl/5.6.1
/home/stas/lib/perl5/site_perl
);

Another way is to write code to modify @INC explicitly:

BEGIN {
unshift @INC,
qw(/home/stas/lib/perl5/5.6.1/i386-linux
/home/stas/lib/perl5/5.6.1
/home/stas/lib/perl5/site_perl/5.6.1/i386-linux
/home/stas/lib/perl5/site_perl/5.6.1
/home/stas/lib/perl5/site_perl
);
}
perl  modules  path  devel  webdevel  solution 
october 2014 by kme

Copy this bookmark:





to read