Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

anditsung's avatar

add nova custom field to packagist

hello. im following the guide here to create a package and submit it to packagist

https://tighten.co/blog/publishing-your-first-laravel-nova-tool

after done all the step and try to install it on my app it was showing an error like this

[InvalidArgumentException]
  Could not find a version of package tsungsoft/nova-custom-field matching your minimum-stability (dev). Require it with an explicit version constraint allowing its desired stab
  ility.

this is the github page i try to publish

https://github.com/anditsung/nova-custom-field

after creating the custom field using

artisan nova:field tsungsoft/nova-custom-field

i just upload it to github without any change.

anyone can give me some insight?

i have add

"minimum-stability": "dev",
    "prefer-stable": true

to the composer.json on the component folder

0 likes
4 replies
bobbybouwmann's avatar

You need to change the composer.json of the project where you want to install this package. Then "minimum-stability": "dev" should work.

Also, it seems that the repo on Github is private since I can't access it ;)

If you want to test your package against a real Laravel app, you should create a release for the created package on Github. This way you can download it without modifying the composer.json. Check this: https://stackoverflow.com/questions/41149552/composer-packagist-could-not-find-package-for-minimum-stability#answer-57801073

1 like
nibri10's avatar

I also have the same error in my package that I went up in packgist is giving the same problem even though I was using the above

my composer.json

{ "name": "nibri10/nova-grid", "description": "Add coluns to create and Update resources", "keywords": [ "laravel", "nova" ],

"license": "MIT",
"require": {
    "php": ">=7.1.0"
   
},
 "require-dev": {
      "nibri10/nova-grid" : "dev-master"
 },
"autoload": {
    "psr-4": {
        "Nibri10\NovaGrid\": "src/"
    }
},
"repositories": [
    {
        "type":"package",
        "package": {
            "name": "nibri10/nova-grid",
            "version":"master",
            "source": {
                "url": "https://github.com/nibri10/nova-grid.git",
                "type": "git",
                "reference":"master"
            }
        }
    }
],
"extra": {
    "laravel": {
        "providers": [
            "Nibri10\NovaGrid\ToolServiceProvider"
        ]
    }
},
"config": {
    "sort-packages": true
},
 "minimum-stability": "dev",
 "prefer-stable": true

}

Please or to participate in this conversation.