Skip to content

Commit 10a715a

Browse files
committed
Added description-related methods
1 parent 5d54f49 commit 10a715a

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

Git.php

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -447,6 +447,26 @@ public function push($remote, $branch)
447447
{
448448
return $this->run("push --tags $remote $branch");
449449
}
450+
451+
/**
452+
* Sets the project description.
453+
*
454+
* @param string $new
455+
*/
456+
public function set_description($new)
457+
{
458+
file_put_contents($this->repo_path."/.git/description", $new);
459+
}
460+
461+
/**
462+
* Gets the project description.
463+
*
464+
* @return string
465+
*/
466+
public function get_description()
467+
{
468+
return file_get_contents($this->repo_path."/.git/description");
469+
}
450470
}
451471

452472
/* End Of File */

0 commit comments

Comments
 (0)