Skip to content

Commit

Permalink
chore: rename r/manfred -> r/moul (#2820)
Browse files Browse the repository at this point in the history
- [x] rename `r/manfred` -> `r/moul`
- [x] switch from `g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq` to
`g1manfred47kzduec920z88wfr64ylksmdcedlf5` vanity addr
- [x] create anti-squatting r/manfred

---------

Signed-off-by: moul <94029+moul@users.noreply.github.com>
Co-authored-by: Morgan <morgan@morganbaz.com>
  • Loading branch information
moul and thehowl authored Sep 26, 2024
1 parent f69880b commit bdc9d0e
Show file tree
Hide file tree
Showing 45 changed files with 117 additions and 109 deletions.
3 changes: 2 additions & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
/examples/gno.land/p/demo/svg/ @moul
/examples/gno.land/p/demo/tamagotchi/ @moul
/examples/gno.land/p/demo/ui/ @moul
/examples/gno.land/p/moul/ @moul
/examples/gno.land/r/demo/ @gnolang/tech-staff @gnolang/devrels
/examples/gno.land/r/demo/art/ @moul
/examples/gno.land/r/demo/memeland/ @leohhhn
Expand All @@ -42,7 +43,7 @@
/examples/gno.land/r/gnoland/ @moul
/examples/gno.land/r/sys/ @moul
/examples/gno.land/r/jaekwon/ @jaekwon
/examples/gno.land/r/manfred/ @moul
/examples/gno.land/r/moul/ @moul

# Gno.land.
/gno.land/ @moul @zivkovicmilos
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/foo20/foo20.gno
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ var (
)

func init() {
admin = ownable.NewWithAddress("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq") // @manfred
admin = ownable.NewWithAddress("g1manfred47kzduec920z88wfr64ylksmdcedlf5") // @moul
banker = grc20.NewBanker("Foo", "FOO", 4)
banker.Mint(admin.Owner(), 1000000*10000) // @administrator (1M)
token = banker.Token()
Expand Down
4 changes: 2 additions & 2 deletions examples/gno.land/r/demo/foo20/foo20_test.gno
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

func TestReadOnlyPublicMethods(t *testing.T) {
var (
admin = pusers.AddressOrName("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
admin = pusers.AddressOrName("g1manfred47kzduec920z88wfr64ylksmdcedlf5")
alice = pusers.AddressOrName(testutils.TestAddress("alice"))
bob = pusers.AddressOrName(testutils.TestAddress("bob"))
)
Expand Down Expand Up @@ -60,7 +60,7 @@ func TestReadOnlyPublicMethods(t *testing.T) {

func TestErrConditions(t *testing.T) {
var (
admin = pusers.AddressOrName("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
admin = pusers.AddressOrName("g1manfred47kzduec920z88wfr64ylksmdcedlf5")
alice = pusers.AddressOrName(testutils.TestAddress("alice"))
empty = pusers.AddressOrName("")
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (

func TestReadOnlyPublicMethods(t *testing.T) {
admin := std.Address("g1us8428u2a5satrlxzagqqa5m6vmuze025anjlj")
manfred := std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
manfred := std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")
unknown := std.Address("g1jg8mtutu9khhfwc4nxmuhcpftf0pajdhfvsqf5") // valid but never used.
NewWithAdmin("Foo", "FOO", 4, 10_000*1_000_000, 0, admin)
NewWithAdmin("Bar", "BAR", 4, 10_000*1_000, 0, admin)
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/groups/z_1_a_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (

var gid groups.GroupID

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/groups/z_2_a_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (

var gid groups.GroupID

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/users.gno
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
// State

var (
admin std.Address = "g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq" // @moul
admin std.Address = "g1manfred47kzduec920z88wfr64ylksmdcedlf5" // @moul

restricted avl.Tree // Name -> true - restricted name
name2User avl.Tree // Name -> *users.User
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_10_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func init() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_11_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_11b_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_2_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_3_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_4_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_5_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_6_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller()
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_7_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_7b_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_8_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/demo/users/z_9_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"gno.land/r/demo/users"
)

const admin = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
const admin = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5")

func main() {
caller := std.GetOrigCaller() // main
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/gnoland/blog/admin.gno
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ var (

func init() {
// adminAddr = std.GetOrigCaller() // FIXME: find a way to use this from the main's genesis.
adminAddr = "g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq"
adminAddr = "g1manfred47kzduec920z88wfr64ylksmdcedlf5" // @moul
}

func AdminSetAdminAddr(addr std.Address) {
Expand Down
16 changes: 8 additions & 8 deletions examples/gno.land/r/gnoland/blog/gnoblog_test.gno
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
)

func TestPackage(t *testing.T) {
std.TestSetOrigCaller(std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq"))
std.TestSetOrigCaller(std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5"))

author := std.GetOrigCaller()

Expand Down Expand Up @@ -59,7 +59,7 @@ Tags: [#tag1](/r/gnoland/blog:t/tag1) [#tag3](/r/gnoland/blog:t/tag3)
Written by moul on 20 May 2022
Published by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq to Gnoland's Blog
Published by g1manfred47kzduec920z88wfr64ylksmdcedlf5 to Gnoland's Blog
---
<details><summary>Comment section</summary>
Expand Down Expand Up @@ -110,20 +110,20 @@ Tags: [#tag1](/r/gnoland/blog:t/tag1) [#tag3](/r/gnoland/blog:t/tag3)
Written by moul on 20 May 2022
Published by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq to Gnoland's Blog
Published by g1manfred47kzduec920z88wfr64ylksmdcedlf5 to Gnoland's Blog
---
<details><summary>Comment section</summary>
<h5>comment4
</h5><h6>by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq on 13 Feb 09 23:31 UTC</h6>
</h5><h6>by g1manfred47kzduec920z88wfr64ylksmdcedlf5 on 13 Feb 09 23:31 UTC</h6>
---
<h5>comment2
</h5><h6>by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq on 13 Feb 09 23:31 UTC</h6>
</h5><h6>by g1manfred47kzduec920z88wfr64ylksmdcedlf5 on 13 Feb 09 23:31 UTC</h6>
---
Expand Down Expand Up @@ -152,20 +152,20 @@ Tags: [#tag1](/r/gnoland/blog:t/tag1) [#tag4](/r/gnoland/blog:t/tag4)
Written by manfred on 20 May 2022
Published by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq to Gnoland's Blog
Published by g1manfred47kzduec920z88wfr64ylksmdcedlf5 to Gnoland's Blog
---
<details><summary>Comment section</summary>
<h5>comment4
</h5><h6>by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq on 13 Feb 09 23:31 UTC</h6>
</h5><h6>by g1manfred47kzduec920z88wfr64ylksmdcedlf5 on 13 Feb 09 23:31 UTC</h6>
---
<h5>comment2
</h5><h6>by g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq on 13 Feb 09 23:31 UTC</h6>
</h5><h6>by g1manfred47kzduec920z88wfr64ylksmdcedlf5 on 13 Feb 09 23:31 UTC</h6>
---
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/gnoland/home/home.gno
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (

var (
override string
admin = ownable.NewWithAddress("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq") // @manfred by default
admin = ownable.NewWithAddress("g1manfred47kzduec920z88wfr64ylksmdcedlf5") // @moul
)

func Render(_ string) string {
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/gnoland/home/overide_filetest.gno
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
)

func main() {
std.TestSetOrigCaller("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
std.TestSetOrigCaller("g1manfred47kzduec920z88wfr64ylksmdcedlf5")
home.AdminSetOverride("Hello World!")
println(home.Render(""))
home.AdminTransferOwnership(testutils.TestAddress("newAdmin"))
Expand Down
2 changes: 1 addition & 1 deletion examples/gno.land/r/gnoland/pages/admin.gno
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ var (

func init() {
// adminAddr = std.GetOrigCaller() // FIXME: find a way to use this from the main's genesis.
adminAddr = "g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq"
adminAddr = "g1manfred47kzduec920z88wfr64ylksmdcedlf5" // @moul
}

func AdminSetAdminAddr(addr std.Address) {
Expand Down
1 change: 0 additions & 1 deletion examples/gno.land/r/manfred/config/gno.mod

This file was deleted.

2 changes: 0 additions & 2 deletions examples/gno.land/r/manfred/home/gno.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
module gno.land/r/manfred/home

require gno.land/r/manfred/config v0.0.0-latest
53 changes: 1 addition & 52 deletions examples/gno.land/r/manfred/home/home.gno
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,56 +1,5 @@
package home

import "gno.land/r/manfred/config"

var (
todos []string
status string
memeImgURL string
)

func init() {
todos = append(todos, "fill this todo list...")
status = "Online" // Initial status set to "Online"
memeImgURL = "https://i.imgflip.com/7ze8dc.jpg"
}

func Render(path string) string {
content := "# Manfred's (gn)home Dashboard\n\n"

content += "## Meme\n"
content += "![](" + memeImgURL + ")\n\n"

content += "## Status\n"
content += status + "\n\n"

content += "## Personal ToDo List\n"
for _, todo := range todos {
content += "- [ ] " + todo + "\n"
}
content += "\n"

// TODO: Implement a feature to list replies on r/boards on my posts
// TODO: Maybe integrate a calendar feature for upcoming events?

return content
}

func AddNewTodo(todo string) {
config.AssertIsAdmin()
todos = append(todos, todo)
}

func DeleteTodo(todoIndex int) {
config.AssertIsAdmin()
if todoIndex >= 0 && todoIndex < len(todos) {
// Remove the todo from the list by merging slices from before and after the todo
todos = append(todos[:todoIndex], todos[todoIndex+1:]...)
} else {
panic("Invalid todo index")
}
}

func UpdateStatus(newStatus string) {
config.AssertIsAdmin()
status = newStatus
return "Moved to r/moul"
}
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package config

import "std"

var addr = std.Address("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq")
var addr = std.Address("g1manfred47kzduec920z88wfr64ylksmdcedlf5") // @moul

func Addr() std.Address {
return addr
Expand Down
1 change: 1 addition & 0 deletions examples/gno.land/r/moul/config/gno.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module gno.land/r/moul/config
3 changes: 3 additions & 0 deletions examples/gno.land/r/moul/home/gno.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module gno.land/r/moul/home

require gno.land/r/moul/config v0.0.0-latest
Loading

0 comments on commit bdc9d0e

Please sign in to comment.