Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: revert "fix(portal-loop): hotfix revert "chore: rename r/manfred -> r/moul (#2820)" (#2865)" #3024

Merged
merged 7 commits into from
Nov 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 @@ -16,7 +16,7 @@ import (
var (
Token, privateLedger = grc20.NewToken("Foo", "FOO", 4)
UserTeller = Token.CallerTeller()
owner = ownable.NewWithAddress("g1u7y667z64x2h7vc6fmpcprgey4ck233jaww9zq") // @manfred
owner = ownable.NewWithAddress("g1manfred47kzduec920z88wfr64ylksmdcedlf5") // @manfred
)

func init() {
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
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 @@ -16,7 +16,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 @@ -17,7 +17,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.

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

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

import (
"gno.land/r/leon/hof"
"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"
hof.Register()
}

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"
}
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
6 changes: 6 additions & 0 deletions examples/gno.land/r/moul/home/gno.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module gno.land/r/moul/home

require (
gno.land/r/leon/hof v0.0.0-latest
gno.land/r/moul/config v0.0.0-latest
)
Loading
Loading