From 71451424c191084c6d79a2fe4806d53f45c6f100 Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Thu, 18 Sep 2025 08:50:31 +0200 Subject: [PATCH 1/8] [ADD] : Pierre115's home - For testing pr on the repo --- packages/r/pierre115/home/gnomod.toml | 2 + packages/r/pierre115/home/myhome.gno | 97 +++++++++++++++++++++++++++ 2 files changed, 99 insertions(+) create mode 100644 packages/r/pierre115/home/gnomod.toml create mode 100644 packages/r/pierre115/home/myhome.gno diff --git a/packages/r/pierre115/home/gnomod.toml b/packages/r/pierre115/home/gnomod.toml new file mode 100644 index 0000000..e846756 --- /dev/null +++ b/packages/r/pierre115/home/gnomod.toml @@ -0,0 +1,2 @@ +module = "gno.land/u/pierre115/home" +gno = "0.9" diff --git a/packages/r/pierre115/home/myhome.gno b/packages/r/pierre115/home/myhome.gno new file mode 100644 index 0000000..2586174 --- /dev/null +++ b/packages/r/pierre115/home/myhome.gno @@ -0,0 +1,97 @@ +package home + +import ( + "strings" + "std" + "gno.land/p/nt/ownable" +) + +var OwnableAddress = ownable.NewWithAddress("g13szarf3rw3jf7m6v43yzwfz5jx0njkezq6hjx3") +var pp = "![test](https://i2.seadn.io/ethereum/0x368ad4a7a7f49b8fa8f34476be0fc4d04ce622f5/22e9f239c16892e578adeea381a4dc6a.png?w=350)" +var projects = []string{ + "[Gnovisu](/r/pierre115/gnovisu) - Lib Svg for Data Visualisation.", +} +var links = []string{ + "[Github](https://github.com/gnolang/hackerspace/issues?q=sort:updated-desc+author:divisio74) - As part of the Epitech student program, I’ll be sharing my progress and insights over the next four months.", +} +var introText = `# Pierre115's Home +## +## About Me +` +var espace = ` +## +` + +var modtext = ` + +I'm Pierre Baud, a second-year student at Epitech Lyon. Before diving into tech, I spent five years in business school, specializing in AI management and Finance where I developed a strong foundation in strategy and innovation. + +Today, I’m passionate about software development and eager to bridge the gap between business and technology. I enjoy working with languages like Go, C/C++, and Python, and I’m currently exploring the blockchain ecosystem through hands-on projects. + +I'm also very interested in dynamic NFTs and their potential to help artists through new forms of creative expression and ownership ! + +` + +func IsAuthorized(addr std.Address) bool { + return addr == OwnableAddress.Owner() +} + +func Render(_ string) string { + content := introText + modtext + espace + RenderPp() + RenderProjects() + RenderLinks() + return strings.ReplaceAll(content, "^", "`") +} + +func RenderProjects() string { + var content string + content += "\n\n## Projects\n\n" + for _, p := range projects { + content += "- " + p + "\n" + } + return content +} + +func RenderPp() string { + return pp +} + +func RenderLinks() string { + var content string + content += "\n\n## Links\n\n" + for _, p := range links { + content += "- " + p + "\n" + } + return content +} + +func UpdateProjects(_ realm, name, url, desc string) { + if !IsAuthorized(std.PreviousRealm().Address()) { + panic("unauthorized") + } + entry := "[" + name + "](" + url + ") - " + desc + projects = append(projects, entry) +} + +func UpdateLinks(_ realm, name, url, desc string) { + if !IsAuthorized(std.PreviousRealm().Address()) { + panic("unauthorized") + } + + entry := "[" + name + "](" + url + ") - " + desc + links = append(links, entry) +} + +func UpdatePp(_ realm, name, url string) { + if !IsAuthorized(std.PreviousRealm().Address()) { + panic("unauthorized") + } + + entry := "![" + name + "](" + url + ")" + pp = entry +} + +func UpdateIntro(_ realm, newText string) { + if !IsAuthorized(std.PreviousRealm().Address()) { + panic("unauthorized") + } + modtext = newText +} From 4751c927571370f187bc1a4381a3e66659dd22b1 Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Sat, 20 Sep 2025 13:54:42 +0200 Subject: [PATCH 2/8] [FIX]: picture not display and new adress --- packages/r/pierre115/home/myhome.gno | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/r/pierre115/home/myhome.gno b/packages/r/pierre115/home/myhome.gno index 2586174..08bae6c 100644 --- a/packages/r/pierre115/home/myhome.gno +++ b/packages/r/pierre115/home/myhome.gno @@ -1,4 +1,4 @@ -package home +package home2 import ( "strings" @@ -6,8 +6,8 @@ import ( "gno.land/p/nt/ownable" ) -var OwnableAddress = ownable.NewWithAddress("g13szarf3rw3jf7m6v43yzwfz5jx0njkezq6hjx3") -var pp = "![test](https://i2.seadn.io/ethereum/0x368ad4a7a7f49b8fa8f34476be0fc4d04ce622f5/22e9f239c16892e578adeea381a4dc6a.png?w=350)" +var OwnableAddress = ownable.NewWithAddress("g1e7r5eglptfejknps3xv2kxv6pc8wvd3wwtw6tg") +var pp = "![png](https://i.imgflip.com/a6o5jb.jpg)" var projects = []string{ "[Gnovisu](/r/pierre115/gnovisu) - Lib Svg for Data Visualisation.", } From 1107d61645a0ecd5f4e05abe2da2fe5f0607fe85 Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Mon, 22 Sep 2025 10:50:48 +0200 Subject: [PATCH 3/8] FIX : Coding-Style --- packages/r/pierre115/home/myhome.gno | 55 ++++++++++++++-------------- 1 file changed, 28 insertions(+), 27 deletions(-) diff --git a/packages/r/pierre115/home/myhome.gno b/packages/r/pierre115/home/myhome.gno index 08bae6c..26d871a 100644 --- a/packages/r/pierre115/home/myhome.gno +++ b/packages/r/pierre115/home/myhome.gno @@ -3,41 +3,32 @@ package home2 import ( "strings" "std" + "gno.land/p/nt/ownable" + "gno.land/p/moul/md" ) -var OwnableAddress = ownable.NewWithAddress("g1e7r5eglptfejknps3xv2kxv6pc8wvd3wwtw6tg") -var pp = "![png](https://i.imgflip.com/a6o5jb.jpg)" -var projects = []string{ - "[Gnovisu](/r/pierre115/gnovisu) - Lib Svg for Data Visualisation.", -} -var links = []string{ - "[Github](https://github.com/gnolang/hackerspace/issues?q=sort:updated-desc+author:divisio74) - As part of the Epitech student program, I’ll be sharing my progress and insights over the next four months.", -} -var introText = `# Pierre115's Home -## -## About Me -` -var espace = ` -## -` - -var modtext = ` - -I'm Pierre Baud, a second-year student at Epitech Lyon. Before diving into tech, I spent five years in business school, specializing in AI management and Finance where I developed a strong foundation in strategy and innovation. - -Today, I’m passionate about software development and eager to bridge the gap between business and technology. I enjoy working with languages like Go, C/C++, and Python, and I’m currently exploring the blockchain ecosystem through hands-on projects. - -I'm also very interested in dynamic NFTs and their potential to help artists through new forms of creative expression and ownership ! +var ( + OwnableAddress = ownable.NewWithAddress("g1e7r5eglptfejknps3xv2kxv6pc8wvd3wwtw6tg") + pp = "![png](https://i.imgflip.com/a6o5jb.jpg)" + projects = []string{ + "[Gnovisu](/r/pierre115/gnovisu) - Lib Svg for Data Visualisation.", + } + links = []string{ + "[Github](https://github.com/gnolang/hackerspace/issues?q=sort:updated-desc+author:divisio74) - As part of the Epitech student program, I’ll be sharing my progress and insights over the next four months.", + "[Linkedin](https://www.linkedin.com/in/pierre-baud-/) - Feel free to connect with me on LinkedIn!", + } + HomeTitle = md.H1("Pierre115's Home") + ScndTitle = md.H2("About Me") +) -` func IsAuthorized(addr std.Address) bool { return addr == OwnableAddress.Owner() } func Render(_ string) string { - content := introText + modtext + espace + RenderPp() + RenderProjects() + RenderLinks() + content := HomeTitle + ScndTitle + modtext + RenderPp() + RenderProjects() + RenderLinks() return strings.ReplaceAll(content, "^", "`") } @@ -63,7 +54,7 @@ func RenderLinks() string { return content } -func UpdateProjects(_ realm, name, url, desc string) { +func AddProjects(_ realm, name, url, desc string) { if !IsAuthorized(std.PreviousRealm().Address()) { panic("unauthorized") } @@ -71,7 +62,7 @@ func UpdateProjects(_ realm, name, url, desc string) { projects = append(projects, entry) } -func UpdateLinks(_ realm, name, url, desc string) { +func AddLinks(_ realm, name, url, desc string) { if !IsAuthorized(std.PreviousRealm().Address()) { panic("unauthorized") } @@ -95,3 +86,13 @@ func UpdateIntro(_ realm, newText string) { } modtext = newText } + +var modtext = md.H3(` + +I'm Pierre Baud, a second-year student at Epitech Lyon. Before diving into tech, I spent five years in business school, specializing in AI management and Finance where I developed a strong foundation in strategy and innovation. + +Today, I’m passionate about software development and eager to bridge the gap between business and technology. I enjoy working with languages like Go, C/C++, and Python, and I’m currently exploring the blockchain ecosystem through hands-on projects. + +I'm also very interested in dynamic NFTs and their potential to help artists through new forms of creative expression and ownership ! + +`) From 005642236c1603f88c86c1dc71352f271571acea Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Mon, 29 Sep 2025 14:33:56 +0200 Subject: [PATCH 4/8] Fix: Better use of md --- packages/r/pierre115/home/gnomod.toml | 2 +- .../r/pierre115/home/{myhome.gno => home.gno} | 40 +++++++------------ 2 files changed, 15 insertions(+), 27 deletions(-) rename packages/r/pierre115/home/{myhome.gno => home.gno} (73%) diff --git a/packages/r/pierre115/home/gnomod.toml b/packages/r/pierre115/home/gnomod.toml index e846756..f530493 100644 --- a/packages/r/pierre115/home/gnomod.toml +++ b/packages/r/pierre115/home/gnomod.toml @@ -1,2 +1,2 @@ -module = "gno.land/u/pierre115/home" +module = "gno.land/r/pierre115/home" gno = "0.9" diff --git a/packages/r/pierre115/home/myhome.gno b/packages/r/pierre115/home/home.gno similarity index 73% rename from packages/r/pierre115/home/myhome.gno rename to packages/r/pierre115/home/home.gno index 26d871a..e065b57 100644 --- a/packages/r/pierre115/home/myhome.gno +++ b/packages/r/pierre115/home/home.gno @@ -10,47 +10,39 @@ import ( var ( OwnableAddress = ownable.NewWithAddress("g1e7r5eglptfejknps3xv2kxv6pc8wvd3wwtw6tg") - pp = "![png](https://i.imgflip.com/a6o5jb.jpg)" + + Picture = "![png](https://i.imgflip.com/a6o5jb.jpg)" + projects = []string{ "[Gnovisu](/r/pierre115/gnovisu) - Lib Svg for Data Visualisation.", } + links = []string{ "[Github](https://github.com/gnolang/hackerspace/issues?q=sort:updated-desc+author:divisio74) - As part of the Epitech student program, I’ll be sharing my progress and insights over the next four months.", - "[Linkedin](https://www.linkedin.com/in/pierre-baud-/) - Feel free to connect with me on LinkedIn!", + "[Linkedin](https://www.linkedin.com/in/pierre-baud-/) - Feel free to connect with me on LinkedIn!", } - HomeTitle = md.H1("Pierre115's Home") - ScndTitle = md.H2("About Me") ) - func IsAuthorized(addr std.Address) bool { return addr == OwnableAddress.Owner() } func Render(_ string) string { - content := HomeTitle + ScndTitle + modtext + RenderPp() + RenderProjects() + RenderLinks() - return strings.ReplaceAll(content, "^", "`") + content := md.H1("Pierre115's Home") + md.H2("About Me") + modtext + Picture + RenderProjects() + RenderLinks() + return strings.ReplaceAll(content, "^", "") } func RenderProjects() string { var content string content += "\n\n## Projects\n\n" - for _, p := range projects { - content += "- " + p + "\n" - } + content += md.BulletList(projects) return content } -func RenderPp() string { - return pp -} - func RenderLinks() string { var content string content += "\n\n## Links\n\n" - for _, p := range links { - content += "- " + p + "\n" - } + content += md.BulletList(links) return content } @@ -58,7 +50,7 @@ func AddProjects(_ realm, name, url, desc string) { if !IsAuthorized(std.PreviousRealm().Address()) { panic("unauthorized") } - entry := "[" + name + "](" + url + ") - " + desc + entry := md.Link(name, url) + " - " + desc projects = append(projects, entry) } @@ -66,18 +58,16 @@ func AddLinks(_ realm, name, url, desc string) { if !IsAuthorized(std.PreviousRealm().Address()) { panic("unauthorized") } - - entry := "[" + name + "](" + url + ") - " + desc + entry := md.Link(name, url) + " - " + desc links = append(links, entry) } -func UpdatePp(_ realm, name, url string) { +func UpdatePicture(_ realm, name, url string) { if !IsAuthorized(std.PreviousRealm().Address()) { panic("unauthorized") } - - entry := "![" + name + "](" + url + ")" - pp = entry + entry := md.Image(name, url) + Picture = entry } func UpdateIntro(_ realm, newText string) { @@ -88,11 +78,9 @@ func UpdateIntro(_ realm, newText string) { } var modtext = md.H3(` - I'm Pierre Baud, a second-year student at Epitech Lyon. Before diving into tech, I spent five years in business school, specializing in AI management and Finance where I developed a strong foundation in strategy and innovation. Today, I’m passionate about software development and eager to bridge the gap between business and technology. I enjoy working with languages like Go, C/C++, and Python, and I’m currently exploring the blockchain ecosystem through hands-on projects. I'm also very interested in dynamic NFTs and their potential to help artists through new forms of creative expression and ownership ! - `) From 0177f3d6b26cecfe5e6d8735065ae18743f15870 Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Fri, 3 Oct 2025 14:51:04 +0200 Subject: [PATCH 5/8] Fix: Resolve CI --- packages/r/pierre115/home/home.gno | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/r/pierre115/home/home.gno b/packages/r/pierre115/home/home.gno index e065b57..28ddbee 100644 --- a/packages/r/pierre115/home/home.gno +++ b/packages/r/pierre115/home/home.gno @@ -1,4 +1,4 @@ -package home2 +package home import ( "strings" From c96163f79db139f4619bcaac8bc02940cacdb75a Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Fri, 3 Oct 2025 18:34:32 +0200 Subject: [PATCH 6/8] Fix: ci (std lib removed) --- packages/r/pierre115/home/home.gno | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/r/pierre115/home/home.gno b/packages/r/pierre115/home/home.gno index 28ddbee..9e4fe26 100644 --- a/packages/r/pierre115/home/home.gno +++ b/packages/r/pierre115/home/home.gno @@ -2,7 +2,7 @@ package home import ( "strings" - "std" + "chain/runtime" "gno.land/p/nt/ownable" "gno.land/p/moul/md" @@ -23,7 +23,7 @@ var ( } ) -func IsAuthorized(addr std.Address) bool { +func IsAuthorized(addr address) bool { return addr == OwnableAddress.Owner() } @@ -47,7 +47,7 @@ func RenderLinks() string { } func AddProjects(_ realm, name, url, desc string) { - if !IsAuthorized(std.PreviousRealm().Address()) { + if !IsAuthorized(runtime.PreviousRealm().Address()) { panic("unauthorized") } entry := md.Link(name, url) + " - " + desc @@ -55,7 +55,7 @@ func AddProjects(_ realm, name, url, desc string) { } func AddLinks(_ realm, name, url, desc string) { - if !IsAuthorized(std.PreviousRealm().Address()) { + if !IsAuthorized(runtime.PreviousRealm().Address()) { panic("unauthorized") } entry := md.Link(name, url) + " - " + desc @@ -63,7 +63,7 @@ func AddLinks(_ realm, name, url, desc string) { } func UpdatePicture(_ realm, name, url string) { - if !IsAuthorized(std.PreviousRealm().Address()) { + if !IsAuthorized(runtime.PreviousRealm().Address()) { panic("unauthorized") } entry := md.Image(name, url) @@ -71,7 +71,7 @@ func UpdatePicture(_ realm, name, url string) { } func UpdateIntro(_ realm, newText string) { - if !IsAuthorized(std.PreviousRealm().Address()) { + if !IsAuthorized(runtime.PreviousRealm().Address()) { panic("unauthorized") } modtext = newText From ceadd4e18719f552a2eb1562efc3639cafd95eb7 Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Wed, 8 Oct 2025 14:05:42 +0200 Subject: [PATCH 7/8] Fix: CI check home.gno --- packages/r/pierre115/home/home.gno | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/r/pierre115/home/home.gno b/packages/r/pierre115/home/home.gno index 9e4fe26..3f75d74 100644 --- a/packages/r/pierre115/home/home.gno +++ b/packages/r/pierre115/home/home.gno @@ -1,11 +1,11 @@ package home import ( - "strings" "chain/runtime" + "strings" - "gno.land/p/nt/ownable" "gno.land/p/moul/md" + "gno.land/p/nt/ownable" ) var ( From ec9a32806e8ff5aa2fc44cb6559b3bead75714ab Mon Sep 17 00:00:00 2001 From: Pierre Baud Date: Mon, 20 Oct 2025 10:47:39 +0200 Subject: [PATCH 8/8] Fix: Unnecessary Export for render function --- packages/r/pierre115/home/home.gno | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/r/pierre115/home/home.gno b/packages/r/pierre115/home/home.gno index 3f75d74..41799d0 100644 --- a/packages/r/pierre115/home/home.gno +++ b/packages/r/pierre115/home/home.gno @@ -28,18 +28,18 @@ func IsAuthorized(addr address) bool { } func Render(_ string) string { - content := md.H1("Pierre115's Home") + md.H2("About Me") + modtext + Picture + RenderProjects() + RenderLinks() + content := md.H1("Pierre115's Home") + md.H2("About Me") + modtext + Picture + renderProjects() + renderLinks() return strings.ReplaceAll(content, "^", "") } -func RenderProjects() string { +func renderProjects() string { var content string content += "\n\n## Projects\n\n" content += md.BulletList(projects) return content } -func RenderLinks() string { +func renderLinks() string { var content string content += "\n\n## Links\n\n" content += md.BulletList(links)