Software & Coding Articles

Page 38 of 83

How to eject the USB device from the system using PowerShell?

Chirag Nagrekar
Chirag Nagrekar
Updated on 17-May-2021 5K+ Views

To eject the USB device from the system, we first need to get the USB device using PowerShell. WMI class Win32_Volume will help us to find the USB device.We know that all removal devices using the DriveType '2'. So we will filter out the USB device among the listed devices.PS C:\> $usbdev = gwmi win32_volume | where{$_.DriveType -eq '2'}The below commands will helpful to unallocated the USB from the system.PS C:\> $usbdev.DriveLetter = $null PS C:\> $usbdev.Put()OutputPath : \localhost\root\cimv2:Win32_Volume.DeviceID="\\?\Volume{6e4d6f1e-a8c2-11eb-9493-005056c00008}" RelativePath : Win32_Volume.DeviceID="\\?\Volume{6e4d6f1e-a8c2-11eb-9493-005056c00008}" Server : localhost NamespacePath : root\cimv2 ClassName : Win32_Volume IsClass : False IsInstance : True IsSingleton : FalseAnd ...

Read More

How to check if the USB device is connected to the system using PowerShell?

Chirag Nagrekar
Chirag Nagrekar
Updated on 17-May-2021 4K+ Views

To retrieve the USB-connected devices using Powershell, we need to retrieve all the drives using the WMI object or CIM Instance and need to filter the win32_diskdrive class with the USB as shown below.So basically, USB devices and other removable devices have the drivetype '2'. You can search with the InterfaceType or the DriveType.WMI commands, gwmi win32_diskdrive | where{$_.Interfacetype -eq "USB"}Alternatively, With the CIM commands, Get-CimInstance -ClassName Win32_DiskDrive | where{$_.InterfaceType -eq 'USB'}orGet-CimInstance -ClassName Win32_LogicalDisk | where{$_.DriveType -eq '2'}If there is no USB device connected to the system, there will be no output. To retrieve the USB disk on the remote ...

Read More

How to create a Test Strategy Document?

Vineet Nanda
Vineet Nanda
Updated on 13-May-2021 538 Views

Before learning about Test Strategy Document, you must understand Test Plan. A test plan is a document containing the scope, methods, and objectives of software testing. Since many companies deal with multiple projects, the project team needs to prepare a goal-centric test plan considering the specific requirements of each project.Regardless of the nature of the project (support or development), proper planning remains the significant stepping stone for any testing process. Apart from a brief introduction to the project, the test plan also contains methods and types of testing that testers should execute during the testing.The Test strategy is a document ...

Read More

Explain Agile Software Process and its Principles

Vineet Nanda
Vineet Nanda
Updated on 13-May-2021 376 Views

The Agile Manifesto first appeared in 2001. It sought to alter the software creation process. The manifesto has four key aspects, but few people are aware of the 12 Agile Principles. They provide more specific explanations of the process in which agile product development can be carried out. After many years, nearly all companies claim that they provide "agile services", but most only pay lip service to the Agile Manifesto's ideas and concepts. The software development industry has also evolved dramatically. It's worth revisiting the agile standards to check their meanings and whether they're still relevant.Timely and Consistent Delivery of ...

Read More

How to add collaborators to a repository in GitHub?

Kannan Sudhakaran
Kannan Sudhakaran
Updated on 30-Apr-2021 5K+ Views

Even if you have a public repository in GitHub, not everyone has the permission to push code into your repository. Other users have a read-only access and cannot modify the repository. In order to allow other individuals to make changes to your repository, you need to invite them to collaborate to the project.The following steps should be performed to invite other team members to collaborate with your repository.Step 1 − Click on the Settings tab in the right corner of the GitHub page.Step 2 − Go to Manage Access option under the Settings tab. On the Manage Access page, you ...

Read More

How to create a GitHub repository

Kannan Sudhakaran
Kannan Sudhakaran
Updated on 30-Apr-2021 2K+ Views

A GitHub account is a pre-requisite for creating a GitHub repository. Follow the below steps after registering with GitHub.Step 1 − Login to the GitHub account. Once you login to your account you will see a ‘+’ button on the right. Click on the button and select "New repository" option to create a new repository.Configure the following in the create a new repository page.Repository name: GitHub will validate the repository name that you have entered.Type of the repository: GitHub lets you create the following types of repositories −Private repository − Private Repository is the one that can be accessed only ...

Read More

How to clone a GitHub repository?

Kannan Sudhakaran
Kannan Sudhakaran
Updated on 30-Apr-2021 2K+ Views

Cloning a repository involves downloading a copy of the source code from source control. In other words, cloning is creating a copy of an existing repository. Consider an example where multiple users are working on a project. This feature can be used by the users to create a development copy.If you have a GitHub repository, you need to first invite collaborators into the repository. Each collaborator will then clone the repository into their local machines.Locally they will work with this cloned repository, make local changes and perform commits on it. Once they are ready to share their changes with others ...

Read More

Explain rebasing in Git

Kannan Sudhakaran
Kannan Sudhakaran
Updated on 30-Apr-2021 1K+ Views

Rebasing alters a sequence of commits. It moves or relocates a sequence of commits from current branch to the target branch. By default, the commits from the current branch that are not already on the other branch are rebased. Rebasing technique allows us to keep a linear history.Let us understand from this from the diagram below.To rebase we need to be in the branch which needs to be rebased into the target. In our scenario, we need to execute the rebase command on the feature branch. After executing the rebase command we will get a linear history.After executing the rebase ...

Read More

How to undo a faulty merge with reset command in Git?

Kannan Sudhakaran
Kannan Sudhakaran
Updated on 30-Apr-2021 2K+ Views

Let us say we performed a merge commit and later found out that the code is not compiling or our application is not working. This happens if we make mistakes while merging. In situations like these we need to undo the merge using either −reset command; ORrevert commandThe git reset command can be used to undo local changes to the state of a Git repository. A git reset moves the HEAD pointer to a given commit and updates the index to match that commit. This command rewrites the commit history. However, if we have shared our commits with other team ...

Read More

Explain soft reset with an example in Git

Kannan Sudhakaran
Kannan Sudhakaran
Updated on 30-Apr-2021 902 Views

Soft reset will move the HEAD pointer to the commit specified. This will not reset the staging area or the working directory.ExampleThe diagram shows a file named File1.txt within the git repository. A, B, C and D represent lines that are added to the file. The diagram indicates that a commit is performed after adding each line A, B and C. c1 is the commit performed after adding line A, c2 is the commit after adding line B and C3 represents the commit after adding line C.Now add line D. This change is available in the working directory and this ...

Read More
Showing 371–380 of 825 articles
« Prev 1 36 37 38 39 40 83 Next »
Advertisements