Import-Module is a powershell cmdlet that adds modules to the current session.
Questions tagged [import-module]
134 questions
116
votes
5 answers
Error:No such property: GROUP for class: org.gradle.api.publication.maven.internal.ant.DefaultGroovyMavenDeployer
I want to use RecyclerViewLib in my project and for that I downloaded it and imported it as a module to my empty "hello world" Android project. I am using android studio v1.0.1 using sdk manager v24 and this is my app/build.gradle
apply plugin:…

max
- 5,963
- 12
- 49
- 80
52
votes
1 answer
How to update an imported module in Android Studio?
While I develop an Android App, I have a library which I have created as separate Android Studio project and can use it by inserting it into new projects. I insert the library by choosing 'File|New|Import Module...' option.
The thing is that after…

Dr. Ehsan Ali
- 4,735
- 4
- 23
- 37
46
votes
3 answers
PowerShell Import-Module vs Dot Sourcing
If I want to separate out some of my functionality from my main PowerShell script, I can either write that as a .ps1 file and dot source the same or I can create that as a .psm1 and import the same using Import-Module.
Which one is better and why?

RinoTom
- 2,278
- 2
- 26
- 40
41
votes
4 answers
ConfigParser vs. import config
ConfigParser is the much debated vanilla configuration parser for Python.
However you can simply import config where config.py has python code which sets configuration parameters.
What are the pros\cons of these two approaches of configuration?
When…

Jonathan Livni
- 101,334
- 104
- 266
- 359
37
votes
5 answers
What's the difference between Add-PsSnapIn and Import-Module
Powershell has two means for importing additional cmdlets into a session, Add-PsSnapIn and Import-Module. The docs are not at all clear regarding when one would chose one over the other. Does anybody know the difference between these?

Justin R.
- 23,435
- 23
- 108
- 157
29
votes
3 answers
Editing an already imported module
Before importing my powershell module (MyModule.psm1), I have written one function in it:
Function T1()
{
Write-Host "T1 is just called" -ForegroundColor red
}
In my MyModule.psd1:
@{
PowerShellVersion = '2.0'
PowerShellHostName = ''
…

Farrukh Waheed
- 2,163
- 2
- 29
- 59
14
votes
2 answers
PowerShell 4 - Import-Module : The specified module 'SQLPS' was not loaded because no valid module file was found in any module directory
Previously working with PowerShell 3. Upgraded to PowerShell 4 and uninstalled it as facing error stated.
Import-Module : The specified module 'SQLPS' was not loaded because no valid module file was found in any module directory. But all SQL…

Yogesh Patel
- 818
- 2
- 12
- 26
12
votes
1 answer
Android NDK import-module / code reuse
Morning!
I've created a small NDK project which allows dynamic serialisation of objects between Java and C++ through JNI. The logic works like this:
Bean -> JavaCInterface.Java -> JavaCInterface.cpp -> JavaCInterface.java -> Bean
The problem is I…

Graeme
- 25,714
- 24
- 124
- 186
10
votes
6 answers
Suppressing VERBOSE for Import-Module
I'm importing Carbon into my PowerShell script; however when running my script with -Verbose, Carbon also outputs a lot of VERBOSE statements.
Is it possible to Import-Module silently such that I can ignore the verbose statements in the imported…

Brett Postin
- 11,215
- 10
- 60
- 95
9
votes
4 answers
PowerShell: Import-Module, but no "ExportedCommands" available
When I use
Import-Module -Name -Verbose
the cmdlets contained in the DLL file are not exported.
Thus, when I type Get-Module my imported module is listed, but without any ExportedCommands. Why?
ModuleType Name …

H. Seeger
- 91
- 1
- 1
- 4
8
votes
1 answer
Powershell: How to get -whatif to propagate to cmdlets in another module
I've been trying write safe code that supports -whatif with the ShouldProcess method so my users have an idea of what a cmdlet is supposed to do before they run it for real.
However I’ve run into a bit of a snag. If I call a script with -whatif as…

shopsinc
- 183
- 1
- 4
8
votes
1 answer
How to correctly ignore Import-Module errors in PowerShell
I'm currently having issues whilst calling Import-Module with Powershell and would be grateful for some advice.
According to previous questions and answers here, the following error, when received whilst trying to import a module using PowerShell,…

AndrewB
- 108
- 1
- 1
- 5
6
votes
2 answers
Permanently add PowerShell module? (Import-Module)
I'm using a third-party module I found on GitHub and importing it with:
powershell Import-Module .\foo.ps1
This imports successfully and the module works great. But when I open a new PowerShell terminal, it doesn't load the module, I have to run…

vskbdvds
- 163
- 2
- 2
- 7
6
votes
2 answers
Cannot find module with tag in import path (Android NDK)
I am getting so frustrated with this issue. I keep getting it and I cannot figure out why. Here is my Android.mk in src/jni
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := tutorial01
LOCAL_SRC_FILES :=…

MoMo
- 186
- 1
- 3
- 15
6
votes
1 answer
What is the difference between Add-PSSnapin and Import-Module in PowerShell?
Possible Duplicate:
What’s the difference between Add-PsSnapIn and Import-Module
What is the difference between Add-PSSnapin and Import-Module in PowerShell?
At the end, both seem like they provide the same result.
Which one is the recommended…

Samselvaprabu
- 16,830
- 32
- 144
- 230