To use your Github private composer package as your local package you need to download it from github
![How to use Github private Composer package as a local package for Laravel using Composer 2 git clone](https://xgenious.com/wp-content/uploads/2022/12/image-4-1024x261.webp)
or you can clone it using this command
git clone <repository url>
if you are trying to use xgenoius private package as local repository then you will get the file in
“@core/vendor/xgenious/packagename”
![How to use Github private Composer package as a local package for Laravel using Composer 3 xgenious laravel private package](https://xgenious.com/wp-content/uploads/2022/12/image-5-1024x550.webp)
you might found only core in our latest project, in older project we used @core
Now make a folder inside @core or core folder name it as packages and copy package file here
![How to use Github private Composer package as a local package for Laravel using Composer 4 copy package file to folder](https://xgenious.com/wp-content/uploads/2022/12/image-6.webp)
if you download from github, you might found tags with the package folder name , rename it with only package name.
go to @core or core > composer.json file open it and remove the vcs package code
![How to use Github private Composer package as a local package for Laravel using Composer 5 load package from github](https://xgenious.com/wp-content/uploads/2022/12/image-7-1024x490.webp)
add below code to point the local package we copied in your packages folder
![How to use Github private Composer package as a local package for Laravel using Composer 6 add composer code for load local package](https://xgenious.com/wp-content/uploads/2022/12/image-8-1024x493.webp)
if you are using our xgneious script , you need to remove the our private packages first to load it from locally
composer remove xgenious/paymentgateway then need to change composer.json code to point to local package
![How to use Github private Composer package as a local package for Laravel using Composer 7 image 9](https://xgenious.com/wp-content/uploads/2022/12/image-9.webp)
if you see any it asking for token, hit enter for abort. then follow below part for user it as local package
"repositories": [
{
"type": "path",
"url": "packages/paymentgateway"
}
],
"require": {
"php": "^8.0.2",
"xgenious/paymentgateway": "dev-master"
},
now run composer require command the package
composer require xgenious/paymentgateway
that’s all now it should work fine with your composer local package, you can us any other package with the script now./