@@ -600,6 +600,53 @@ Keep the following in mind when filing an issue:
600
600
Respect your fellow contributors. For example, "The docs are terrible" is not
601
601
helpful or polite feedback.
602
602
603
+ ## Announcement management
604
+
605
+ An announcement is a _ regular Hugo page_ contained under the ` announcements `
606
+ section of a locale. This means that we leverage Hugo's builtin handling of page
607
+ dates (future or expired), internationalization, and more, to automatically show
608
+ or hide banners depending on the build date, determine banner ordering, handle
609
+ fall back to English banners, etc.
610
+
611
+ > Announcements are currently used as banners only. We _ might_ eventually
612
+ > support slightly more general announcements as well.
613
+
614
+ ### Creating an announcement
615
+
616
+ To add a new announcement, create an announcement markdown file under the
617
+ ` announcements ` folder of your localization using the following command:
618
+
619
+ ``` sh
620
+ hugo new --kind announcement content/YOUR-LOCALE/announcements/announcement-file-name.md
621
+ ```
622
+
623
+ Adjust according to your desired locale and file name. Add the announcement text
624
+ as the body of the page.
625
+
626
+ > For banners, the announcement body should be a short phrase.
627
+
628
+ {{% alert title="For localizations" %}}
629
+
630
+ If you are creating a ** locale specific announcement override** , make sure that
631
+ you use the ** same filename** as the English language announcement.
632
+
633
+ {{% /alert %}}
634
+
635
+ ### Announcement list
636
+
637
+ Any given announcement will appear in a site build when the build date falls
638
+ between the ` date ` and ` expiryDate ` fields of the announcement. When those
639
+ fields are missing they are assumed to be "now" and "forever", respectively.
640
+
641
+ Announcements will appear in the standard page order as determined using Hugo's
642
+ [ Regular pages] ( https://gohugo.io/methods/site/regularpages/ ) function. That is,
643
+ the "lightest" announcements (by ` weight ` ) will appear first; when weights are
644
+ the same or unspecified, the most recent announcements (by ` date ` ) will appear
645
+ first, etc.
646
+
647
+ So, if you want to force an announcement to the top, use a negative ` weight ` in
648
+ the front matter.
649
+
603
650
## Contribute to other repositories
604
651
605
652
OpenTelemetry is an open source project, and we gladly accept new contributions
0 commit comments