{"id":42043,"date":"2024-02-06T13:26:32","date_gmt":"2024-02-06T18:26:32","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=42043"},"modified":"2024-02-06T13:28:25","modified_gmt":"2024-02-06T18:28:25","slug":"pkl-programming-language","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2024\/02\/06\/pkl-programming-language\/","title":{"rendered":"Pkl Programming Language"},"content":{"rendered":"<p><a href=\"https:\/\/pkl-lang.org\/blog\/introducing-pkl.html\">Apple<\/a> (via <a href=\"https:\/\/news.ycombinator.com\/item?id=39232976\">Hacker<\/a> <a href=\"https:\/\/news.ycombinator.com\/item?id=39239265\">News<\/a>):<\/p>\n<blockquote cite=\"https:\/\/pkl-lang.org\/blog\/introducing-pkl.html\">\n<p>We are delighted to announce the open source first release of Pkl (pronounced Pickle), a programming language for producing configuration.<\/p>\n<p>[&#8230;]<\/p>\n<p>We created Pkl because we think that configuration is best expressed as a blend between a static language and a general-purpose programming language. We want to take the best of both worlds; to provide a language that is declarative and simple to read and write, but enhanced with capabilities borrowed from general-purpose languages. When writing Pkl, you are able to use the language features you&rsquo;d expect, like classes, functions, conditionals, and loops. You can build abstraction layers, and share code by creating packages and publishing them. Most importantly, you can use Pkl to meet many different types of configuration needs. It can be used to produce static configuration files in any format, or be embedded as a library into another application runtime.<\/p>\n<p>[&#8230;]<\/p>\n<p>When binding to a language, Pkl schema can be generated as classes\/structs in the target language. For example, the Application.pkl example from above can be generated into Swift, Go, Java, and Kotlin.<\/p>\n<\/blockquote>\n\n<p><a href=\"https:\/\/mastodon.social\/@danielpunkass\/111865652348408243\">Daniel Jalkut<\/a>:<\/p>\n<blockquote cite=\"https:\/\/mastodon.social\/@danielpunkass\/111865652348408243\"><p>Who had &ldquo;Apple will release a new language, implemented in Kotlin, with IDE integration for everything but Xcode&rdquo; on their bingo card?<\/p><\/blockquote>\n\n<p><a href=\"https:\/\/twitter.com\/_mischi\/status\/1753698467011010732\">_mischi<\/a>:<\/p>\n<blockquote cite=\"https:\/\/twitter.com\/_mischi\/status\/1753698467011010732\">\n<p>Vision Pro is cool and all, but have you ever spent time searching for that format error in your YAML file?<\/p>\n<\/blockquote>\n\n<p><a href=\"https:\/\/mastodon.social\/@heckj\/111874511235877744\">Joe Heck<\/a>:<\/p>\n<blockquote cite=\"https:\/\/mastodon.social\/@heckj\/111874511235877744\">\n<p>The choice of package\/module configuration IN swift was a decision I wish had been revisited back prior to Swift3 - so many ongoing and upgrading complications from that alone.<\/p>\n<\/blockquote>","protected":false},"excerpt":{"rendered":"<p>Apple (via Hacker News): We are delighted to announce the open source first release of Pkl (pronounced Pickle), a programming language for producing configuration. [&#8230;] We created Pkl because we think that configuration is best expressed as a blend between a static language and a general-purpose programming language. We want to take the best of [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"2024-02-06T18:26:35Z","apple_news_api_id":"363e729f-a9dc-48e0-810c-f2c39f5b63b8","apple_news_api_modified_at":"2024-02-06T18:26:35Z","apple_news_api_revision":"AAAAAAAAAAD\/\/\/\/\/\/\/\/\/\/w==","apple_news_api_share_url":"https:\/\/apple.news\/ANj5yn6ncSOCBDPLDn1tjuA","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[4],"tags":[38,507,1525,46,74,2551,71,901,866,2552],"class_list":["post-42043","post","type-post","status-publish","format-standard","hentry","category-programming-category","tag-apple","tag-json","tag-kotlin-programming-language","tag-languagedesign","tag-opensource","tag-pkl-programming-language","tag-programming","tag-swift-programming-language","tag-xml","tag-yaml"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/42043","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=42043"}],"version-history":[{"count":1,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/42043\/revisions"}],"predecessor-version":[{"id":42044,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/42043\/revisions\/42044"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=42043"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=42043"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=42043"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}