-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
045fd03
commit 05802b9
Showing
4 changed files
with
22 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
4 changes: 4 additions & 0 deletions
4
packaging/application/github.com/xujihui1985/application/readme.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
### rule | ||
|
||
#### cmd is where binary live, we should put all related binary in one library | ||
#### internal is the pkg which can not be seen by other project, they are reusable across multiple binaries |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
### rule | ||
|
||
#### all package in same level can not depend on each other | ||
#### try not to import thirdpart library |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
### Mechanics | ||
|
||
In Go, all packages are "first class", and the only hierarchy is what you define in the source tree | ||
for your project | ||
|
||
Two packages can't cross import each other. imports are a one way steet | ||
|
||
### Design | ||
|
||
#### to be purposeful, packages must provide, not contain | ||
#### to be usable, packages must be designed with the user as their focus | ||
#### packages must be intuitive and simple to use | ||
#### Packages must protect the users application from cascading changes | ||
#### packages must reduce taking on opinions when it's reasonable and practical |