Skip to content

Commit 9f80243

Browse files
lnuJanDeDobbeleer
authored andcommitted
feat(php): extensions added + doc updated
1 parent 68a0d5f commit 9f80243

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

docs/docs/segment-php.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
id: php
33
title: php
4-
sidebar_label: php
4+
sidebar_label: PHP
55
---
66

77
## What
@@ -32,5 +32,5 @@ Display the currently active php version.
3232
- missing_command_text: `string` - text to display when the command is missing - defaults to empty
3333
- display_mode: `string` - determines when the segment is displayed
3434
- `always`: the segment is always displayed
35-
- `files`: the segment is only displayed when `*.php` files are present (default)
35+
- `files`: the segment is only displayed when `*.php, composer.json, composer.lock, .php-version` files are present (default)
3636
- enable_hyperlink: `bool` - display an hyperlink to the php release notes - defaults to `false`

docs/sidebars.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ module.exports = {
4848
"os",
4949
"owm",
5050
"path",
51+
"php",
5152
"python",
5253
"root",
5354
"ruby",
@@ -59,7 +60,6 @@ module.exports = {
5960
"text",
6061
"time",
6162
"ytm",
62-
"php",
6363
],
6464
},
6565
{

src/segment_php.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ func (n *php) init(props *properties, env environmentInfo) {
1212
n.language = &language{
1313
env: env,
1414
props: props,
15-
extensions: []string{"*.php", "composer.json", ".php-version"},
15+
extensions: []string{"*.php", "composer.json", "composer.lock", ".php-version"},
1616
commands: []*cmd{
1717
{
1818
executable: "php",

0 commit comments

Comments
 (0)